Re: [PATCH v2 03/10] nvme-multipath: add error handling support for add_disk()

2021-09-27 Thread Hannes Reinecke
On 9/28/21 12:00 AM, Luis Chamberlain wrote: We never checked for errors on add_disk() as this function returned void. Now that this is fixed, use the shiny new error handling. Since we now can tell for sure when a disk was added, move setting the bit NVME_NSHEAD_DISK_LIVE only when we did add t

Re: [PATCH v2 03/10] nvme-multipath: add error handling support for add_disk()

2021-09-27 Thread Keith Busch
On Mon, Sep 27, 2021 at 03:00:32PM -0700, Luis Chamberlain wrote: > + /* > + * test_and_set_bit() is used because it is protecting against two nvme > + * paths simultaneously calling device_add_disk() on the same namespace > + * head. > + */ > if (!test_and_set_bit(NVM

[PATCH v2 03/10] nvme-multipath: add error handling support for add_disk()

2021-09-27 Thread Luis Chamberlain
We never checked for errors on add_disk() as this function returned void. Now that this is fixed, use the shiny new error handling. Since we now can tell for sure when a disk was added, move setting the bit NVME_NSHEAD_DISK_LIVE only when we did add the disk successfully. Nothing to do here as th