25 Jan, 2008

1 commit


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

    Jean Delvare
     

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

    Scott Wood
     

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

    David Brownell
     

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

    David Brownell
     

05 Jan, 2006

1 commit


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

    Russell King
     

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

    Russell King
     

30 Oct, 2005

1 commit