diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2007-02-20 09:04:34 +0100 |
---|---|---|
committer | Stefan Roese <sr@denx.de> | 2007-02-20 09:04:34 +0100 |
commit | 735dd97b1b20e777d059c7b389fe9d70cd3f80c7 (patch) | |
tree | eb62a0abe8bdea88c563380c302a88fa64eff151 /common/cmd_scsi.c | |
parent | 620d3c9a14affca29a5c4e575e9f355c2bd4aed2 (diff) | |
download | u-boot-735dd97b1b20e777d059c7b389fe9d70cd3f80c7.tar.gz u-boot-735dd97b1b20e777d059c7b389fe9d70cd3f80c7.tar.xz u-boot-735dd97b1b20e777d059c7b389fe9d70cd3f80c7.zip |
[PATCH 1_4] Merge common get_dev() routines for block devices
Each of the filesystem drivers duplicate the get_dev routine. This change
merges them into a single function in part.c
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'common/cmd_scsi.c')
-rw-r--r-- | common/cmd_scsi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/common/cmd_scsi.c b/common/cmd_scsi.c index cc08743d5d..b17bebbacf 100644 --- a/common/cmd_scsi.c +++ b/common/cmd_scsi.c @@ -194,7 +194,7 @@ void scsi_init(void) block_dev_desc_t * scsi_get_dev(int dev) { - return((block_dev_desc_t *)&scsi_dev_desc[dev]); + return (dev < CFG_SCSI_MAX_DEVICE) ? &scsi_dev_desc[dev] : NULL; } |