Skip to content

Commit

Permalink
[SCSI] Fix sd_probe_domain config problem
Browse files Browse the repository at this point in the history
With CONFIG_BLK_DEV_SD = n and CONFIG_PM = n, you get this compile failure:

(.text+0x4f6c77): undefined reference to `scsi_sd_probe_domain'

This was introduced by

commit a7a20d1
Author: Dan Williams <dan.j.williams@intel.com>
Date:   Thu Mar 22 17:05:11 2012 -0700

    [SCSI] sd: limit the scope of the async probe domain

And happens because scsi_sd_probe_domain is conditionally defined but
unconditionally used.  Fix this by making the symbol unconditionally defined.

Reported-by: Randy Dunlap <rdunlap@xenotime.net>
Cc: Dan Williams <dan.j.williams@intel.com>
Tested-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
  • Loading branch information
James Bottomley authored and James Bottomley committed Jun 7, 2012
1 parent a2c6585 commit ea80dad
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/scsi/scsi.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,11 +90,9 @@ unsigned int scsi_logging_level;
EXPORT_SYMBOL(scsi_logging_level);
#endif

#if IS_ENABLED(CONFIG_PM) || IS_ENABLED(CONFIG_BLK_DEV_SD)
/* sd and scsi_pm need to coordinate flushing async actions */
/* sd, scsi core and power management need to coordinate flushing async actions */
LIST_HEAD(scsi_sd_probe_domain);
EXPORT_SYMBOL(scsi_sd_probe_domain);
#endif

/* NB: These are exposed through /proc/scsi/scsi and form part of the ABI.
* You may not alter any existing entry (although adding new ones is
Expand Down

0 comments on commit ea80dad

Please sign in to comment.