Re: [PATCH 2/2] Rework handling of scsi_device.vpd_pg8[03]

2017-08-28 Thread Christoph Hellwig
This looks generally good. But I wonder if there is a way to factor the assining/clearing sequence into little helpers instead of duplicating it?

RE: [PATCH 2/2] Rework handling of scsi_device.vpd_pg8[03]

2017-08-27 Thread Seymour, Shane M
g; Bart Van Assche ; > Christoph Hellwig ; Hannes Reinecke ; > Johannes Thumshirn ; Seymour, Shane M > > Subject: [PATCH 2/2] Rework handling of scsi_device.vpd_pg8[03] > > Introduce struct scsi_vpd for the VPD page length, data and the > RCU head that will be used to free the

[PATCH 2/2] Rework handling of scsi_device.vpd_pg8[03]

2017-08-25 Thread Bart Van Assche
Introduce struct scsi_vpd for the VPD page length, data and the RCU head that will be used to free the VPD data. Use kfree_rcu() instead of kfree() to free VPD data. Only annotate pointers that are shared across threads with __rcu. Use rcu_dereference() when dereferencing an RCU pointer. This patch