25 Jan, 2008
1 commit
-
This name is just passed to platform_device_alloc which has its parameter
declared const.Signed-off-by: Stephen Rothwell
Signed-off-by: Greg Kroah-Hartman
13 Oct, 2007
1 commit
-
While platform_device.id is a u32, platform_device_add() handles "-1"
as a special id value. This has potential for confusion and bugs.
Making it an int instead should prevent problems from happening in
the future.Signed-off-by: Jean Delvare
Signed-off-by: Greg Kroah-Hartman
14 Dec, 2006
1 commit
-
platform_device_add_data() makes a copy of the data that is given to it,
and thus the parameter can be const. This removes a warning when data
from get_property() on powerpc is handed to platform_device_add_data(),
as get_property() returns a const pointer.Signed-off-by: Scott Wood
Signed-off-by: Andrew Morton
Signed-off-by: Greg Kroah-Hartman
02 Dec, 2006
1 commit
-
This defines a new platform_driver_probe() method allowing the driver's
probe() method, and its support code+data, to safely live in __init
sections for typical system configurations.Many system-on-chip processors could benefit from this API, to the tune
of recovering hundreds to thousands of bytes per driver. That's memory
which is currently wasted holding code which can never be called after
system startup, yet can not be removed. It can't be removed because of
the linkage requirement that pointers to init section code (like, ideally,
probe support) must not live in other sections (like driver method tables)
after those pointers would be invalid.Signed-off-by: David Brownell
Signed-off-by: Greg Kroah-Hartman
26 Sep, 2006
1 commit
-
Teach platform_bus about the new suspend_late/resume_early PM calls,
issued with IRQs off. Do we really need sysdev and friends any more,
or can janitors start switching its users over to platform_device so
we can do a minor code-ectomy?Signed-off-by: David Brownell
Signed-off-by: Greg Kroah-Hartman
05 Jan, 2006
1 commit
-
Driver core: add platform_device_del function
Having platform_device_del90 allows more straightforward error
handling code in drivers registering platform devices.Signed-off-by: Dmitry Torokhov
Signed-off-by: Greg Kroah-Hartman
10 Nov, 2005
1 commit
-
Introduce struct platform_driver. This allows the platform device
driver methods to be passed a platform_device structure instead of
instead of a plain device structure, and therefore requiring casting
in every platform driver.We introduce this in such a way that any existing platform drivers
registered directly via driver_register continue to work as before,
thereby allowing a gradual conversion to the new platform_driver
methods.Signed-off-by: Russell King
Acked-by: Greg Kroah-Hartman
06 Nov, 2005
1 commit
-
Re-jig the simple platform device support to allow private data
to be attached to a platform device, as well as allowing the
parent device to be set.Example usage:
pdev = platform_device_alloc("mydev", id);
if (pdev) {
err = platform_device_add_resources(pdev, &resources,
ARRAY_SIZE(resources));
if (err == 0)
err = platform_device_add_data(pdev, &platform_data,
sizeof(platform_data));
if (err == 0)
err = platform_device_add(pdev);
} else {
err = -ENOMEM;
}
if (err)
platform_device_put(pdev);Signed-off-by: Russell King
Acked-by: Greg Kroah-Hartman
30 Oct, 2005
1 commit
-
Signed-off-by: Russell King