lkml.org 
[lkml]   [2024]   [Feb]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    SubjectRe: [PATCH] dma: dma-sysfs: make dma_subsys const
    From
    Date
    Hi Ricardo,

    On Sun, 2024-02-04 at 12:15 -0300, Ricardo B. Marliere wrote:
    > Now that the driver core can properly handle constant struct bus_type,
    > move the dma_subsys variable to be a constant structure as well,
    > placing it into read-only memory which can not be modified at runtime.
    >
    > Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    > Suggested-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    > Signed-off-by: Ricardo B. Marliere <ricardo@marliere.net>
    > ---
    > arch/sh/drivers/dma/dma-sysfs.c | 2 +-
    > 1 file changed, 1 insertion(+), 1 deletion(-)
    >
    > diff --git a/arch/sh/drivers/dma/dma-sysfs.c b/arch/sh/drivers/dma/dma-sysfs.c
    > index 431bc18f0a41..9f666280d80c 100644
    > --- a/arch/sh/drivers/dma/dma-sysfs.c
    > +++ b/arch/sh/drivers/dma/dma-sysfs.c
    > @@ -15,7 +15,7 @@
    > #include <linux/string.h>
    > #include <asm/dma.h>
    >
    > -static struct bus_type dma_subsys = {
    > +static const struct bus_type dma_subsys = {
    > .name = "dma",
    > .dev_name = "dma",
    > };
    >
    > ---
    > base-commit: 6613476e225e090cc9aad49be7fa504e290dd33d
    > change-id: 20240204-bus_cleanup-sh-6d3c136da6bb
    >
    > Best regards,

    Reviewed-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>

    Thanks for your patch. I will merge it into my linux-sh this weekend
    after returning from FOSDEM, either this evening or tomorrow.

    Thanks,
    Adrian

    --
    .''`. John Paul Adrian Glaubitz
    : :' : Debian Developer
    `. `' Physicist
    `- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913

    \
     
     \ /
      Last update: 2024-05-27 14:47    [W:2.822 / U:0.024 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site