coresight: make coresight_bustype const

JIRA: https://issues.redhat.com/browse/RHEL-21456

commit dd95255d44c05c9977f962bf0f2afe5e11f8ab3e
Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Date: Fri, 5 Jan 2024 13:33:32 +0100

    Now that the driver core can properly handle constant struct bus_type,
    move the coresight_bustype variable to be a constant structure as well,
    placing it into read-only memory which can not be modified at runtime.

    Cc: Suzuki K Poulose <suzuki.poulose@arm.com>
    Cc: Mike Leach <mike.leach@linaro.org>
    Cc: James Clark <james.clark@arm.com>
    Cc: Leo Yan <leo.yan@linaro.org>
    Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
    Cc: coresight@lists.linaro.org
    Cc: linux-arm-kernel@lists.infradead.org
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
    Link: https://lore.kernel.org/r/2024010531-tinfoil-avert-4a57@gregkh

Signed-off-by: Mark Salter <msalter@redhat.com>
This commit is contained in:
Mark Salter 2024-10-11 10:13:48 -04:00
parent ac55206e29
commit caad0a64f6
2 changed files with 2 additions and 2 deletions

View File

@ -1815,7 +1815,7 @@ done:
}
EXPORT_SYMBOL_GPL(coresight_alloc_device_name);
struct bus_type coresight_bustype = {
const struct bus_type coresight_bustype = {
.name = "coresight",
};

View File

@ -35,7 +35,7 @@
#define CORESIGHT_UNLOCK 0xc5acce55
extern struct bus_type coresight_bustype;
extern const struct bus_type coresight_bustype;
enum coresight_dev_type {
CORESIGHT_DEV_TYPE_SINK,