• Mark Rutland's avatar
    ARM: 6974/1: pmu: refactor reservation · f12482c9
    Mark Rutland authored
    Currently, PMU platform_device reservation relies on some minor abuse
    of the platform_device::id field for determining the type of PMU. This
    is problematic for device tree based probing, where the ID cannot be
    controlled.
    
    This patch removes reliance on the id field, and depends on each PMU's
    platform driver to figure out which type it is. As all PMUs handled by
    the current platform_driver name "arm-pmu" are CPU PMUs, this
    convention is hardcoded. New PMU types can be supported through the use
    of {of,platform}_device_id tables
    Signed-off-by: default avatarMark Rutland <mark.rutland@arm.com>
    Acked-by: default avatarJamie Iles <jamie@jamieiles.com>
    Acked-by: default avatarWill Deacon <will.deacon@arm.com>
    Cc: Rob Herring <rob.herring@calxeda.com>
    Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
    Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
    f12482c9
pmu.c 3.08 KB