aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pnp
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2009-01-09 03:39:43 -0500
committerLen Brown <len.brown@intel.com>2009-01-09 03:39:43 -0500
commitb2576e1d4408e134e2188c967b1f28af39cd79d4 (patch)
tree004f3c82faab760f304ce031d6d2f572e7746a50 /drivers/pnp
parent3cc8a5f4ba91f67bbdb81a43a99281a26aab8d77 (diff)
parent2150edc6c5cf00f7adb54538b9ea2a3e9cedca3f (diff)
Merge branch 'linus' into release
Diffstat (limited to 'drivers/pnp')
-rw-r--r--drivers/pnp/card.c7
-rw-r--r--drivers/pnp/core.c5
-rw-r--r--drivers/pnp/pnpbios/bioscalls.c2
-rw-r--r--drivers/pnp/system.c2
4 files changed, 7 insertions, 9 deletions
diff --git a/drivers/pnp/card.c b/drivers/pnp/card.c
index e75b060daa95..efea128f02da 100644
--- a/drivers/pnp/card.c
+++ b/drivers/pnp/card.c
@@ -165,8 +165,7 @@ struct pnp_card *pnp_alloc_card(struct pnp_protocol *protocol, int id, char *pnp
165 card->number = id; 165 card->number = id;
166 166
167 card->dev.parent = &card->protocol->dev; 167 card->dev.parent = &card->protocol->dev;
168 sprintf(card->dev.bus_id, "%02x:%02x", card->protocol->number, 168 dev_set_name(&card->dev, "%02x:%02x", card->protocol->number, card->number);
169 card->number);
170 169
171 card->dev.coherent_dma_mask = DMA_24BIT_MASK; 170 card->dev.coherent_dma_mask = DMA_24BIT_MASK;
172 card->dev.dma_mask = &card->dev.coherent_dma_mask; 171 card->dev.dma_mask = &card->dev.coherent_dma_mask;
@@ -295,8 +294,8 @@ int pnp_add_card_device(struct pnp_card *card, struct pnp_dev *dev)
295{ 294{
296 dev->dev.parent = &card->dev; 295 dev->dev.parent = &card->dev;
297 dev->card_link = NULL; 296 dev->card_link = NULL;
298 snprintf(dev->dev.bus_id, BUS_ID_SIZE, "%02x:%02x.%02x", 297 dev_set_name(&dev->dev, "%02x:%02x.%02x",
299 dev->protocol->number, card->number, dev->number); 298 dev->protocol->number, card->number, dev->number);
300 spin_lock(&pnp_lock); 299 spin_lock(&pnp_lock);
301 dev->card = card; 300 dev->card = card;
302 list_add_tail(&dev->card_list, &card->devices); 301 list_add_tail(&dev->card_list, &card->devices);
diff --git a/drivers/pnp/core.c b/drivers/pnp/core.c
index 16c01c6fa7c5..14814f231739 100644
--- a/drivers/pnp/core.c
+++ b/drivers/pnp/core.c
@@ -70,7 +70,7 @@ int pnp_register_protocol(struct pnp_protocol *protocol)
70 spin_unlock(&pnp_lock); 70 spin_unlock(&pnp_lock);
71 71
72 protocol->number = nodenum; 72 protocol->number = nodenum;
73 sprintf(protocol->dev.bus_id, "pnp%d", nodenum); 73 dev_set_name(&protocol->dev, "pnp%d", nodenum);
74 return device_register(&protocol->dev); 74 return device_register(&protocol->dev);
75} 75}
76 76
@@ -145,8 +145,7 @@ struct pnp_dev *pnp_alloc_dev(struct pnp_protocol *protocol, int id, char *pnpid
145 dev->dev.coherent_dma_mask = dev->dma_mask; 145 dev->dev.coherent_dma_mask = dev->dma_mask;
146 dev->dev.release = &pnp_release_device; 146 dev->dev.release = &pnp_release_device;
147 147
148 sprintf(dev->dev.bus_id, "%02x:%02x", dev->protocol->number, 148 dev_set_name(&dev->dev, "%02x:%02x", dev->protocol->number, dev->number);
149 dev->number);
150 149
151 dev_id = pnp_add_id(dev, pnpid); 150 dev_id = pnp_add_id(dev, pnpid);
152 if (!dev_id) { 151 if (!dev_id) {
diff --git a/drivers/pnp/pnpbios/bioscalls.c b/drivers/pnp/pnpbios/bioscalls.c
index 7ff824496b39..7e6b5a3b3281 100644
--- a/drivers/pnp/pnpbios/bioscalls.c
+++ b/drivers/pnp/pnpbios/bioscalls.c
@@ -481,7 +481,7 @@ void pnpbios_calls_init(union pnp_bios_install_struct *header)
481 481
482 set_base(bad_bios_desc, __va((unsigned long)0x40 << 4)); 482 set_base(bad_bios_desc, __va((unsigned long)0x40 << 4));
483 _set_limit((char *)&bad_bios_desc, 4095 - (0x40 << 4)); 483 _set_limit((char *)&bad_bios_desc, 4095 - (0x40 << 4));
484 for (i = 0; i < NR_CPUS; i++) { 484 for_each_possible_cpu(i) {
485 struct desc_struct *gdt = get_cpu_gdt_table(i); 485 struct desc_struct *gdt = get_cpu_gdt_table(i);
486 if (!gdt) 486 if (!gdt)
487 continue; 487 continue;
diff --git a/drivers/pnp/system.c b/drivers/pnp/system.c
index 764f3a310685..59b90922da8c 100644
--- a/drivers/pnp/system.c
+++ b/drivers/pnp/system.c
@@ -26,7 +26,7 @@ static void reserve_range(struct pnp_dev *dev, resource_size_t start,
26 resource_size_t end, int port) 26 resource_size_t end, int port)
27{ 27{
28 char *regionid; 28 char *regionid;
29 const char *pnpid = dev->dev.bus_id; 29 const char *pnpid = dev_name(&dev->dev);
30 struct resource *res; 30 struct resource *res;
31 31
32 regionid = kmalloc(16, GFP_KERNEL); 32 regionid = kmalloc(16, GFP_KERNEL);