]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
[SCSI] libsas: fix try_test_sas_gpio_gp_bit() build error
authorDan Williams <dan.j.williams@intel.com>
Fri, 23 Sep 2011 23:43:45 +0000 (16:43 -0700)
committerJames Bottomley <JBottomley@Parallels.com>
Sun, 2 Oct 2011 17:47:40 +0000 (12:47 -0500)
If the user has disabled CONFIG_SCSI_SAS_HOST_SMP then libsas drivers
will not be receiving smp-gpio frames and do not need this lookup code.

Reported-by: Randy Dunlap <rdunlap@xenotime.net>
Tested-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
include/scsi/libsas.h

index ac9d80c93c68af6731e2088e58d268356946085e..d455fa96dc8c0b1e5ed935e2ae1ce189369b7700 100644 (file)
@@ -413,7 +413,14 @@ static inline unsigned int to_sas_gpio_od(int device, int bit)
        return 3 * device + bit;
 }
 
+#ifdef CONFIG_SCSI_SAS_HOST_SMP
 int try_test_sas_gpio_gp_bit(unsigned int od, u8 *data, u8 index, u8 count);
+#else
+static inline int try_test_sas_gpio_gp_bit(unsigned int od, u8 *data, u8 index, u8 count)
+{
+       return -1;
+}
+#endif
 
 /* ---------- Tasks ---------- */
 /*