kern/123095 kern/131602 sendfile

Andriy Gapon avg at freebsd.org
Thu Jul 8 09:59:53 UTC 2010


on 08/07/2010 12:40 Andriy Gapon said the following:
> on 08/07/2010 11:40 Andriy Gapon said the following:
>> on 08/07/2010 11:29 Kostik Belousov said the following:
>>> Right, the patch maps the page in sf buffer read-only (on i386 only).
>>> But note the parallel posting with m_cat() change. It is still not enough,
>>> and I am not set up for the real network testing ATM.
>> Could you also try to experiment with mb_dupcl?
>> Namely transfer M_RDONLY from source mbuf.
> 
> 
> Oh, sigh, should have looked at definition of M_WRITABLE() first.

As kib has just pointed out to me, m_ext.ref_cnt may go back to one (via source
mbuf going away) and then destination mbuf becomes R/W.
BTW, perhaps m_collapse() should also use M_WRITABLE instead of directly testing
M_RDONLY?

-- 
Andriy Gapon


More information about the freebsd-net mailing list