Why? I'm definitely sure that IPX patches are correct: only
place which accesses spx_family_ops variable is ipx_create.
If we have SPX sockets created when we call ipx_unregister_spx, we
have much worse problem, because of regardless of any cli/sti, we are
going to release af_spx memory very soon, and cli does not force us to
close all SPX sockets, does it?
As for p8022/psnap changes, yes, I missed datalink_header locking.
But because of IPX uses dl->datalink_header() happilly from process
context without any locking, I thought that users of proto structure
returned from register_* are responsible for making sure that they'll
not use it anymore when they call unregister_*. Adding (any) lock
into *_datalink_header will not help unless you will call find_*_client
in *_datalink_header after obtaining lock to revalidate pointer you
received from caller. Which is obviously wrong, I'd say. And ipx
requires you to down all interfaces/close all sockets before it will
call unregister_*_client, so IPX is safe here (at least as it was always;
if kernel can send packets to downed interface, it is completely another
problem).
Thanks for explanation,
Petr Vandrovec
vandrove@vc.cvut.cz
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/