Bjorn Helgaas
1e5ad96790
resources: when allocate_resource() fails, leave resource untouched
...
When "allocate_resource(root, new, size, ...)" fails, we currently
clobber "new". This is inconvenient for the caller, who might care
about the original contents of the resource.
For example, when pci_bus_alloc_resource() fails, the "can't allocate
mem resource %pR" message from pci_assign_resources() currently contains
junk for the resource start/end.
This patch delays the "new" update until we're about to return success.
Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Acked-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2009-11-04 13:06:46 -08:00
..
2009-09-21 14:29:21 +02:00
2009-10-11 11:20:58 -07:00
2009-11-03 11:03:09 +01:00
2009-10-11 11:20:58 -07:00
2009-10-24 11:07:51 +02:00
2009-08-24 11:33:40 +10:00
2009-09-24 03:50:25 -04:00
2009-09-24 03:50:26 -04:00
2009-09-24 03:50:26 -04:00
2009-09-24 07:20:58 -07:00
2009-10-29 07:39:25 -07:00
2009-09-15 09:19:38 -07:00
2009-09-24 07:20:58 -07:00
2009-09-23 11:02:26 -07:00
2009-09-18 09:48:52 -07:00
2009-10-29 07:39:25 -07:00
2009-11-03 07:52:39 -08:00
2009-07-18 14:19:53 +02:00
2009-08-10 15:41:12 +02:00
2009-10-28 20:34:34 +01:00
2009-10-05 12:04:16 -07:00
2009-09-24 07:21:04 -07:00
2009-08-29 14:10:07 +02:00
2009-09-23 07:39:30 -07:00
2009-07-29 19:10:34 -07:00
2009-09-19 13:13:17 -07:00
2009-09-23 18:12:10 -07:00
2009-10-01 16:11:11 -07:00
2009-09-09 17:30:06 +02:00
2009-07-24 10:53:29 +02:00
2009-09-23 07:39:29 -07:00
2009-10-09 15:56:44 +02:00
2009-09-24 07:20:57 -07:00
2009-10-01 16:11:11 -07:00
2009-10-11 11:20:58 -07:00
2009-09-24 07:20:58 -07:00
2009-10-08 12:16:35 -07:00
2009-10-29 08:56:20 +10:30
2009-10-23 09:35:02 +02:00
2009-09-24 07:21:04 -07:00
2009-09-22 07:17:38 -07:00
2009-08-29 14:10:07 +02:00
2009-08-21 21:43:46 +02:00
2009-09-23 07:39:28 -07:00
2009-09-20 20:15:40 +02:00
2009-09-24 07:20:59 -07:00
2009-10-07 08:11:20 +02:00
2009-09-23 19:46:30 +02:00
2009-10-15 20:33:01 +02:00
2009-10-07 08:11:20 +02:00
2009-10-15 20:33:01 +02:00
2009-10-15 20:33:01 +02:00
2009-09-27 11:39:25 -07:00
2009-10-01 16:11:13 -07:00
2009-11-04 13:06:46 -08:00
2009-08-06 05:50:21 +02:00
2009-09-30 22:56:10 +02:00
2009-08-02 14:26:09 +02:00
2009-09-17 10:17:25 +02:00
2009-10-14 15:02:34 +02:00
2009-09-17 10:17:25 +02:00
2009-09-21 09:53:55 +02:00
2009-09-21 09:53:55 +02:00
2009-10-29 09:19:29 -07:00
2009-09-24 07:21:01 -07:00
2009-09-24 07:21:04 -07:00
2009-09-24 09:34:47 +09:30
2009-09-17 15:53:44 -04:00
2009-09-24 07:21:04 -07:00
2009-08-31 18:08:50 +02:00
2009-09-24 15:13:11 -07:00
2009-10-29 08:20:00 -07:00
2009-10-29 07:39:30 -07:00
2009-09-24 07:53:22 -07:00
2009-07-12 14:03:27 -07:00
2009-09-15 10:17:30 +02:00
2009-09-23 09:46:15 -07:00
2009-09-21 15:14:55 +02:00
2009-09-23 18:13:10 -07:00
2009-09-24 07:21:04 -07:00
2009-08-10 14:43:09 +02:00
2009-10-29 08:20:00 -07:00