diff options
author | David Brownell <david-b@pacbell.net> | 2007-06-03 13:50:40 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-06-04 13:25:09 -0700 |
commit | e44a45ae7b7f7c7a4ebd6aa39b703bf2b97fe848 (patch) | |
tree | 883ba41f63b5c001d28b57ce8fc592a9bb2fa3c7 /drivers/spi | |
parent | c1a13ff57ab1ce52a0aae9984594dbfcfbaf68c0 (diff) | |
download | linux-3.10-e44a45ae7b7f7c7a4ebd6aa39b703bf2b97fe848.tar.gz linux-3.10-e44a45ae7b7f7c7a4ebd6aa39b703bf2b97fe848.tar.bz2 linux-3.10-e44a45ae7b7f7c7a4ebd6aa39b703bf2b97fe848.zip |
SPI dynamic busid generation bugfix
Fix SPI dynamic bus ID assignment to start at 2^15-1 rather than a negative
number. Valid bus ids are supposed to be positive, and are (now) stored in
an 's16' value.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/spi')
-rw-r--r-- | drivers/spi/spi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c index c3219b29b5a..4831edbae2d 100644 --- a/drivers/spi/spi.c +++ b/drivers/spi/spi.c @@ -411,7 +411,7 @@ EXPORT_SYMBOL_GPL(spi_alloc_master); */ int spi_register_master(struct spi_master *master) { - static atomic_t dyn_bus_id = ATOMIC_INIT((1<<16) - 1); + static atomic_t dyn_bus_id = ATOMIC_INIT((1<<15) - 1); struct device *dev = master->cdev.dev; int status = -ENODEV; int dynamic = 0; |