Re: [PATCH 01/11] scsi/fcoe: lock online CPUs in fcoe_percpu_clean()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Mar 11, 2016 at 04:28:53PM +0100, Sebastian Andrzej Siewior wrote:
> for_each_possible_cpu() with a cpu_online() + `thread' check possibly does
> the job. But there is a tiny race: Say CPU5 is reported online but is
> going down. And after fcoe_percpu_clean() saw that CPU5 is online it
> decided to enqueue a packet. After dev_alloc_skb() returned a skb
> that CPU is offline (or say the notifier destroyed the kthread). So we
> would OOps because `thread' is NULL.
> An alternative would be to lock the CPUs during our loop (so no CPU is
> going away) and then we iterate over the online mask.

I've looked over this and the following patches, and I suspect
the right thing to do for fcoe and bnx2 is to convert them to use the
generic workqueue code instead of reinventing it poorly.
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux