On Thu, Mar 27, 2008 at 8:35 AM, Paul Clements <paul.clements@steeleye.com> wrote:I believe that NBD_CLEAR_SOCK from 'nbd-client -d' sets it to NULL. lo->sock is already NULL on entry to sock_xmit(). So simply checking if the sock_xmit's 'sock' is NULL _should_ avoid any possibility of a NULL pointer Oops because sock can't be !NULL after the negative check (because of the sock = lo->sock assignment). That is, unless I'm missing somewhere in the rest of the kernel (not nbd) that would take action to set a socket to NULL? The attached patch seems reasonable. I'll be testing today to verify it fixes the problem. I'm aware tx_lock can't be held over both; I was suggesting maybe another lock but that feels like overkill. I use 'nbd-client -d' and then resort to 'kill -9' IFF 'nbd-client -d' returned non-zero. But it sounds like simply using 'kill -9' could be a near-term workaround, I'll try this as well and will report back. thanks, Mike
| Arjan van de Ven | [patch] Add basic sanity checks to the syscall execution patch |
| debian developer | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| monstr | Microblaze init port |
| Linus Torvalds | Re: Back to the future. |
git: | |
| Petr Baudis | Re: Cleaning up git user-interface warts |
| Jan Engelhardt | about c8af1de9 (git status uses pager) |
| Jakub Narebski | Re: VCS comparison table |
| Linus Torvalds | Re: kernel.org mirroring (Re: [GIT PULL] MMC update) |
| Richard Stallman | Real men don't attack straw men |
| Marco Peereboom | Re: Real men don't attack straw men |
| David Newman | setting dscp or tos bits |
| Khalid Schofield | Configuring sendmail openbsd 4.2 |
| Christoph Hellwig | Re: [PATCH RFC] [1/9] Core module symbol namespaces code and intro. |
| Josip Rodin | bnx2_poll panicking kernel |
| Johannes Berg | [RFC v2] mac80211: assign needed_headroom/tailroom for netdevs |
| Francois Romieu | Re: NAPI, rx_no_buffer_count, e1000, r8169 and other actors |
