Re: [PATCH v7 3/9] Introduce scsi_device_being_removed()

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

 



Am , schrieb Bart Van Assche:
On 12/07/12 11:02, Rolf Eike Beer wrote:
Am , schrieb Bart Van Assche:
On 12/07/12 09:40, Rolf Eike Beer wrote:
diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h
index 55367b0..767dd16 100644
--- a/include/scsi/scsi_device.h
+++ b/include/scsi/scsi_device.h
@@ -442,6 +442,11 @@ static inline int scsi_device_created(struct
scsi_device *sdev)
     return sdev->sdev_state == SDEV_CREATED ||
         sdev->sdev_state == SDEV_CREATED_BLOCK;
 }
+static inline int scsi_device_being_removed(struct scsi_device *sdev)
+{
+    return sdev->sdev_state == SDEV_CANCEL ||
+        sdev->sdev_state == SDEV_DEL;
+}

 /* accessor functions for the SCSI parameters */
 static inline int scsi_device_sync(struct scsi_device *sdev)

Newline missing before the new function.

Hello Rolf,

Well spotted. Did you realize I had left out the newline on purpose,
to preserve consistency with the rest of the header file ?

Well, there is already a newline between scsi_device_created() and
scsi_device_sync() where you insert your stuff so this sort of
consistency is hard to spot.

Hello Eike,

So you really care about these blank lines ? How about the patch below ?

Well, that was not the intent of the message. I just saw that you introduced something that looked like an error. You explained why you did it, I explained why I did not notice that before.

It is identical to the patch at the start of this thread except that it adds a blank line between each pair of functions in <scsi/scsi_device.h>
where there was not yet a blank line.

Since you already did the patch I think we should take this one ;)

Eike
--
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