* Re: [PATCH v1] fbdev/offb: fix PCI device reference leak on probe failure
From: 최유호 @ 2026-05-05 11:22 UTC (permalink / raw)
To: Helge Deller
Cc: Jason, linux-fbdev, dri-devel, linux-kernel, mhun512, ae878000,
tmk5904
In-Reply-To: <2bf485cd-0c6d-4f0e-99d6-7b592b949a1f@gmx.de>
Dear Helge,
Thanks for letting me know that the patches were merged.
Best regards,
Yuho Choi
On Tue, 5 May 2026 at 06:10, Helge Deller <deller@gmx.de> wrote:
>
> On 5/5/26 03:39, dbgh9129@gmail.com wrote:
> > I am sending a gentle ping on this patch. Please let me know if you
> > have any feedback or if any changes are required.
>
> Both of your patches (offb and savagefb) were merged upstream 13 days ago:
> https://git.kernel.org/pub/scm/linux/kernel/git/deller/linux-fbdev.git/log/?h=fbdev-7.1-2
>
> Usually I send "patch applied" messages, but in this case I probably forgot.
>
> Helge
^ permalink raw reply
* [PATCH 6.6.y] firmware: google: framebuffer: Do not unregister platform device
From: Sasha Levin @ 2026-05-05 12:01 UTC (permalink / raw)
To: stable
Cc: Thomas Zimmermann, Tzung-Bi Shih, Julius Werner,
Javier Martinez Canillas, Hans de Goede, linux-fbdev, Sasha Levin
In-Reply-To: <2026050336-tainted-hundredth-63d4@gregkh>
From: Thomas Zimmermann <tzimmermann@suse.de>
[ Upstream commit 5cd28bd28c8ce426b56ce4230dbd17537181d5ad ]
The native driver takes over the framebuffer aperture by removing the
system- framebuffer platform device. Afterwards the pointer in drvdata
is dangling. Remove the entire logic around drvdata and let the kernel's
aperture helpers handle this. The platform device depends on the native
hardware device instead of the coreboot device anyway.
When commit 851b4c14532d ("firmware: coreboot: Add coreboot framebuffer
driver") added the coreboot framebuffer code, the kernel did not support
device-based aperture management. Instead native driviers only removed
the conflicting fbdev device. At that point, unregistering the framebuffer
device most likely worked correctly. It was definitely broken after
commit d9702b2a2171 ("fbdev/simplefb: Do not use struct
fb_info.apertures"). So take this commit for the Fixes tag. Earlier
releases might work depending on the native hardware driver.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Fixes: d9702b2a2171 ("fbdev/simplefb: Do not use struct fb_info.apertures")
Acked-by: Tzung-Bi Shih <tzungbi@kernel.org>
Acked-by: Julius Werner <jwerner@chromium.org>
Cc: Thomas Zimmermann <tzimmermann@suse.de>
Cc: Javier Martinez Canillas <javierm@redhat.com>
Cc: Hans de Goede <hansg@kernel.org>
Cc: linux-fbdev@vger.kernel.org
Cc: <stable@vger.kernel.org> # v6.3+
Link: https://patch.msgid.link/20260217155836.96267-2-tzimmermann@suse.de
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
drivers/firmware/google/framebuffer-coreboot.c | 10 ----------
1 file changed, 10 deletions(-)
diff --git a/drivers/firmware/google/framebuffer-coreboot.c b/drivers/firmware/google/framebuffer-coreboot.c
index c323a818805cc..a83ef081efe02 100644
--- a/drivers/firmware/google/framebuffer-coreboot.c
+++ b/drivers/firmware/google/framebuffer-coreboot.c
@@ -64,22 +64,12 @@ static int framebuffer_probe(struct coreboot_device *dev)
sizeof(pdata));
if (IS_ERR(pdev))
pr_warn("coreboot: could not register framebuffer\n");
- else
- dev_set_drvdata(&dev->dev, pdev);
return PTR_ERR_OR_ZERO(pdev);
}
-static void framebuffer_remove(struct coreboot_device *dev)
-{
- struct platform_device *pdev = dev_get_drvdata(&dev->dev);
-
- platform_device_unregister(pdev);
-}
-
static struct coreboot_driver framebuffer_driver = {
.probe = framebuffer_probe,
- .remove = framebuffer_remove,
.drv = {
.name = "framebuffer",
},
--
2.53.0
^ permalink raw reply related
* Re: Plan to fix nvidia_wmi_ec backlight issues, help wanted
From: Daniel Dadap @ 2026-05-05 15:51 UTC (permalink / raw)
To: Hans de Goede
Cc: Lee Jones, Daniel Thompson, Jingoo Han, Helge Deller,
Rafael J. Wysocki, dri-devel@lists.freedesktop.org, linux-fbdev,
linux-acpi, platform-driver-x86@vger.kernel.org
In-Reply-To: <f10c039b-e9ef-4aae-8291-8f1e71074586@oss.qualcomm.com>
Thanks, Hans -
On Tue, May 05, 2026 at 11:52:55AM +0200, Hans de Goede wrote:
> <resend adding pdx86 list, sorry>
>
> Hi All,
>
> A while ago Nvidia introduced a new Nvidia specific firmware method
> for controlling the backlight on laptops with runtime switchable
> Nvidia hybrid graphics.
>
> This is supported through the nvidia-wmi-ec-backlight driver, but has
> never worked 100%.
>
> The new WMI firmware interface has a method to ask the firmware if
> the backlight is controlled though the EC and this the new WMI interface
> should be used; or if it is directly controlled by the GPU and the GPU
> driver's native backlight support should be used.
>
> There are several bugs in the implementation of this on various laptops:
>
> 1. The method to get the backlight control source sometimes does not
> report the correct value.
>
> 2. On some laptop models which method (native-gpu vs nvidia-wmi) works
> changes at runtime, e.g. when plugging in a charger.
>
> Known affected laptop models/bug reports about this:
> - Acer Predator PH315-55: needs acpi_backlight=native
> - Dell G15 5515 with RTX 3050: *needs* acpi_backlight=native
> - Dell G15 5515 with RTX 3060: *breaks* with acpi_backlight=native
> - Lenovo Legion Slim 7 2021
> - https://bugzilla.kernel.org/show_bug.cgi?id=217026
> - https://gitlab.gnome.org/GNOME/gnome-settings-daemon/-/work_items/784
> - https://gitlab.freedesktop.org/drm/amd/-/issues/4512
> - https://bugzilla.suse.com/show_bug.cgi?id=1217750
I believe there were also a couple of cases where different builds of the
same notebook (as far as DMI quirks tables could detect) would be driven
by different methods, exacerbating problem (1) because adding a quirtk to
fix one notebook would break other versions of the "same" notebook. (Oh,
maybe that's the two G15 5515 bugs linked above.)
>
> It turns out that under Windows both a WMI backlight driver and a GPU
> native backlight driver get installed and Windows simply always calls
> both when the backlight changes working around these kind of firmware
> bugs.
>
Yes, it's frustrating that so many notebooks have implementations of this
interface that have bugs that get masked by Windows always using both of
the interfaces. I wonder whether Windows behaves this way because bugs of
this type are so prevalent, or if the bugs are prevalent because Windows
always behaved that way so nobody noticed.
> When this first came up, about 2 years ago, I came up with the below
> plan to fix this. Nvidia was supposed to work in implementing this,
> but so far an implementation of this plan has not happened.
>
> Note I do not have time to work on this myself. I'm posting this here
> in the hope that either Nvidia will pick this up after all; or that
> someone else can make this happen.
>
> I'm more then happy to help answering any questions which may come up
> while implementing this; and to review the resulting patches.
>
Sorry about that - I totally forgot about this proposal. I'm still happy
to help here, although if someone else is especially eager to implement
these changes, I'm also happy to answer questions, test, review, and help
in other ways as bandwidth allows. I have some clarifying questions about
the plan - it's been some time since we talked about this, so I apologize
if I've already asked these questions and you've already answered them.
>
> The plan
> ========
>
> 1. Modify the core backlight code to allow registering a backlight-device
> for in kernel use only, disabling the registering of a class device under
> /sys/class/backlight .
>
> 2. Add a new backlight-aggregate.c backlight driver, which exports a
> devm_backlight_aggregate_register_or_add() function. Drivers can call
> this passing in an existing backlight-device (with its sysfs interface
> disabled). This either creates a singleton /sys/class/backlight/aggregate
> device, or adds the passed in backlight to the existing singleton instance
> if it already exists.
>
> This new driver always exposes a range of 0-255 to userspace. This acts
> as a proxie for any backlight-devices registered to be part of
> the aggregate, forwarding any brightness set calls to all backlights,
> scaled to their actual range. For reads this will report the last set
> brightness value (starting with the value of the first registered
> backlight-device).
>
> 3. Add a new nvidia_wmi_ec_and_native type to drivers/acpi/video_detect.c
> for both DMI quirks and commandline handling.
>
So by default both the native and GPU drivers would register a "normal"
backlight handler, and if the "both" quirk is set (or if requested via
kernel command line) they'll register with the aggregate device?
Would it make sense to make this more generic, with a parameter which
can be set via command line or quirks for which backlight devices to
aggregate? And then maybe instead of a new "nvidia_wmi_ec_and_native"
backlight type in video_detect.c, it could be called "aggregate" or
something else along those lines, used in combination with the list of
backlight types to aggregate.
Have we seen systems where both the iGPU and dGPU register their own
native handlers? I vaguely recall seeing such a system, but I do not
keep careful notes about this sort of thing, so I'm not certain. If
there are indeed such systems, then "native" might not be specific
enough, and it may be necessary to explicitly name backlight drivers
individually in order to aggregate them.
>
> 4. Modify acpi_video_backlight_use_native() to also return true if
> the __acpi_video_get_backlight_type() call there returns the new
> acpi_backlight_nvidia_wmi_ec_and_native.
> 5. Add a new devm_backlight_device_register_native() helper which
> calls __acpi_video_get_backlight_type(true, NULL) and if that returns
> the new nvidia_wmi_ec_and_native type then registers the passed in
> backlight with the flag to not register a sysfs class interface and
> then on success calls the new devm_backlight_aggregate_register_or_add()
> with the just registered backlight device; and if the returned type
> instead is acpi_backlight_native register the passed in backlight
> normally through devm_backlight_device_register()
>
> 5. Modify the i915 and amdgpu drivers to use the new
> devm_backlight_device_register_native() helper. Since this new helper
> checks the backlight-type itself, drop acpi_video_backlight_use_native()
> checks *if* the registration is the only thing guarded by that check.
>
> 6. drivers/platform/x86/nvidia-wmi-ec-backlight.c to not return
> early from probe when acpi_video_get_backlight_type() returns
> the new nvidia_wmi_ec_and_native type and for that type make it
> registers its backlight with the flag to not register a sysfs class
> interface and then on success calls the new
> devm_backlight_aggregate_register_or_add().
>
There still isn't anything tying a particular sysfs backlight interface
node to a specific display panel, right? Is there a plan to eventually
support this? How would this interact with that plan? I'm just a little
worried about designing ourselves into a corner that makes things harder
to untangle individual devices later if the need arises.
> Regards,
>
> Hans
>
^ permalink raw reply
* [GIT PULL] fbdev fixes and updates for v7.1-rc3
From: Helge Deller @ 2026-05-05 20:52 UTC (permalink / raw)
To: Linus Torvalds, linux-kernel, linux-fbdev, dri-devel
Hi Linus,
please pull four small patches for fbdev, of which two are important:
One fixes the bitmap font generation and the other prevents a possible
use-after-free in udlfb.
Thanks!
Helge
----------------------------------------------------------------
The following changes since commit 254f49634ee16a731174d2ae34bc50bd5f45e731:
Linux 7.1-rc1 (2026-04-26 14:19:00 -0700)
are available in the Git repository at:
http://git.kernel.org/pub/scm/linux/kernel/git/deller/linux-fbdev.git tags/fbdev-for-7.1-rc3
for you to fetch changes up to 8de779dc40d35d39fa07387b6f921eb11df0f511:
fbdev: udlfb: add vm_ops to dlfb_ops_mmap to prevent use-after-free (2026-05-04 10:35:55 +0200)
----------------------------------------------------------------
fbdev fixes & cleanups for 7.1-rc3:
- Fix rotating fonts by 180 degrees [Thomas Zimmermann]
- Drop duplicate include of linux/module.h in fb_defio [Chen Ni]
- Add vm_ops in udlfb to prevent use-after-free [Rajat Gupta]
- ipu-v3: clean up kernel-doc warnings [Randy Dunlap]
----------------------------------------------------------------
Chen Ni (1):
fbdev: defio: Remove duplicate include of linux/module.h
Rajat Gupta (1):
fbdev: udlfb: add vm_ops to dlfb_ops_mmap to prevent use-after-free
Randy Dunlap (1):
fbdev: ipu-v3: clean up kernel-doc warnings
Thomas Zimmermann (1):
lib/fonts: Fix bit position when rotating by 180 degrees
drivers/video/fbdev/core/fb_defio.c | 1 -
drivers/video/fbdev/udlfb.c | 31 ++++++++++++++++++++++++++++++-
include/video/imx-ipu-image-convert.h | 16 +++++++++++-----
include/video/udlfb.h | 1 +
lib/fonts/font_rotate.c | 2 +-
5 files changed, 43 insertions(+), 8 deletions(-)
^ permalink raw reply
* Re: [GIT PULL] fbdev fixes and updates for v7.1-rc3
From: pr-tracker-bot @ 2026-05-05 23:55 UTC (permalink / raw)
To: Helge Deller; +Cc: Linus Torvalds, linux-kernel, linux-fbdev, dri-devel
In-Reply-To: <afpYkddCLxIsicwb@carbonx1>
The pull request you sent on Tue, 5 May 2026 22:52:33 +0200:
> http://git.kernel.org/pub/scm/linux/kernel/git/deller/linux-fbdev.git tags/fbdev-for-7.1-rc3
has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/13ad98eaabef611f042d49a9077be060ad03284d
Thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/prtracker.html
^ permalink raw reply
* [PATCH] staging: sm750fb: add const to g_fbmode array
From: Chaitanya Sabnis @ 2026-05-06 3:56 UTC (permalink / raw)
To: sudipm.mukherjee, teddy.wang, gregkh
Cc: linux-fbdev, linux-staging, linux-kernel, Chaitanya Sabnis
Fix a checkpatch warning by changing the `g_fbmode` array of
pointers to be `static const char * const`. This ensures that both
the strings and the array of pointers are placed in read-only memory,
preventing unintended modifications and improving security.
Signed-off-by: Chaitanya Sabnis <chaitanya.msabnis@gmail.com>
---
drivers/staging/sm750fb/sm750.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
index dec1f6b88a7d..08d4979c6755 100644
--- a/drivers/staging/sm750fb/sm750.c
+++ b/drivers/staging/sm750fb/sm750.c
@@ -33,7 +33,7 @@
static int g_hwcursor = 1;
static int g_noaccel;
static int g_nomtrr;
-static const char *g_fbmode[] = {NULL, NULL};
+static const char * const g_fbmode[] = {NULL, NULL};
static const char *g_def_fbmode = "1024x768-32@60";
static char *g_settings;
static int g_dualview;
--
2.43.0
^ permalink raw reply related
* Re: [PATCH] staging: sm750fb: add const to g_fbmode array
From: Ahmet Sezgin Duran @ 2026-05-06 6:27 UTC (permalink / raw)
To: Chaitanya Sabnis, sudipm.mukherjee, teddy.wang, gregkh
Cc: linux-fbdev, linux-staging, linux-kernel
In-Reply-To: <20260506035641.5060-1-chaitanya.msabnis@gmail.com>
On 5/6/26 6:56 AM, Chaitanya Sabnis wrote:
> Fix a checkpatch warning by changing the `g_fbmode` array of
> pointers to be `static const char * const`. This ensures that both
> the strings and the array of pointers are placed in read-only memory,
> preventing unintended modifications and improving security.
>
> Signed-off-by: Chaitanya Sabnis <chaitanya.msabnis@gmail.com>
> ---
> drivers/staging/sm750fb/sm750.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> index dec1f6b88a7d..08d4979c6755 100644
> --- a/drivers/staging/sm750fb/sm750.c
> +++ b/drivers/staging/sm750fb/sm750.c
> @@ -33,7 +33,7 @@
> static int g_hwcursor = 1;
> static int g_noaccel;
> static int g_nomtrr;
> -static const char *g_fbmode[] = {NULL, NULL};
> +static const char * const g_fbmode[] = {NULL, NULL};
> static const char *g_def_fbmode = "1024x768-32@60";
> static char *g_settings;
> static int g_dualview;
Did you compile these changes?
Regards,
Ahmet Sezgin Duran
^ permalink raw reply
* Re: [PATCH] staging: sm750fb: add const to g_fbmode array
From: Chaitanya Sabnis @ 2026-05-06 7:14 UTC (permalink / raw)
To: Ahmet Sezgin Duran
Cc: sudipm.mukherjee, teddy.wang, gregkh, linux-fbdev, linux-staging,
linux-kernel
In-Reply-To: <fcfbdb1a-188a-4ab1-b7cc-b2c430d2cca4@sezginduran.net>
On Wed, May 6, 2026 at 11:57 AM Ahmet Sezgin Duran ahmet@sezginduran.net wrote:
Did you compile these changes?
Yes, I have verified the changes by compiling the driver with: make
M=drivers/staging/sm750fb/
The build completed successfully without errors.
Regards,
Chaitanya
^ permalink raw reply
* Re: Plan to fix nvidia_wmi_ec backlight issues, help wanted
From: Armin Wolf @ 2026-05-06 7:46 UTC (permalink / raw)
To: Daniel Dadap, Hans de Goede
Cc: Lee Jones, Daniel Thompson, Jingoo Han, Helge Deller,
Rafael J. Wysocki, dri-devel@lists.freedesktop.org, linux-fbdev,
linux-acpi, platform-driver-x86@vger.kernel.org
In-Reply-To: <afoR5jUHLPXpYJ8a@ddadap-lakeline.nvidia.com>
Am 05.05.26 um 17:51 schrieb Daniel Dadap:
> Thanks, Hans -
>
> On Tue, May 05, 2026 at 11:52:55AM +0200, Hans de Goede wrote:
>> <resend adding pdx86 list, sorry>
>>
>> Hi All,
>>
>> A while ago Nvidia introduced a new Nvidia specific firmware method
>> for controlling the backlight on laptops with runtime switchable
>> Nvidia hybrid graphics.
>>
>> This is supported through the nvidia-wmi-ec-backlight driver, but has
>> never worked 100%.
>>
>> The new WMI firmware interface has a method to ask the firmware if
>> the backlight is controlled though the EC and this the new WMI interface
>> should be used; or if it is directly controlled by the GPU and the GPU
>> driver's native backlight support should be used.
>>
>> There are several bugs in the implementation of this on various laptops:
>>
>> 1. The method to get the backlight control source sometimes does not
>> report the correct value.
>>
>> 2. On some laptop models which method (native-gpu vs nvidia-wmi) works
>> changes at runtime, e.g. when plugging in a charger.
>>
>> Known affected laptop models/bug reports about this:
>> - Acer Predator PH315-55: needs acpi_backlight=native
>> - Dell G15 5515 with RTX 3050: *needs* acpi_backlight=native
>> - Dell G15 5515 with RTX 3060: *breaks* with acpi_backlight=native
>> - Lenovo Legion Slim 7 2021
>> - https://bugzilla.kernel.org/show_bug.cgi?id=217026
>> - https://gitlab.gnome.org/GNOME/gnome-settings-daemon/-/work_items/784
>> - https://gitlab.freedesktop.org/drm/amd/-/issues/4512
>> - https://bugzilla.suse.com/show_bug.cgi?id=1217750
>
> I believe there were also a couple of cases where different builds of the
> same notebook (as far as DMI quirks tables could detect) would be driven
> by different methods, exacerbating problem (1) because adding a quirtk to
> fix one notebook would break other versions of the "same" notebook. (Oh,
> maybe that's the two G15 5515 bugs linked above.)
>
>>
>> It turns out that under Windows both a WMI backlight driver and a GPU
>> native backlight driver get installed and Windows simply always calls
>> both when the backlight changes working around these kind of firmware
>> bugs.
>>
>
> Yes, it's frustrating that so many notebooks have implementations of this
> interface that have bugs that get masked by Windows always using both of
> the interfaces. I wonder whether Windows behaves this way because bugs of
> this type are so prevalent, or if the bugs are prevalent because Windows
> always behaved that way so nobody noticed.
I suspect that both scenarios apply :(
That being said, i am asking myself if "both interfaces" also includes
the backlight interface from the iGPU. If not then we could simply use a
notifier to dynamically tie the WMI device to the Nvidia GPU backlight
interface.
>> When this first came up, about 2 years ago, I came up with the below
>> plan to fix this. Nvidia was supposed to work in implementing this,
>> but so far an implementation of this plan has not happened.
>>
>> Note I do not have time to work on this myself. I'm posting this here
>> in the hope that either Nvidia will pick this up after all; or that
>> someone else can make this happen.
>>
>> I'm more then happy to help answering any questions which may come up
>> while implementing this; and to review the resulting patches.
>>
>
> Sorry about that - I totally forgot about this proposal. I'm still happy
> to help here, although if someone else is especially eager to implement
> these changes, I'm also happy to answer questions, test, review, and help
> in other ways as bandwidth allows. I have some clarifying questions about
> the plan - it's been some time since we talked about this, so I apologize
> if I've already asked these questions and you've already answered them.
>
>>
>> The plan
>> ========
>>
>> 1. Modify the core backlight code to allow registering a backlight-device
>> for in kernel use only, disabling the registering of a class device under
>> /sys/class/backlight .
>>
>> 2. Add a new backlight-aggregate.c backlight driver, which exports a
>> devm_backlight_aggregate_register_or_add() function. Drivers can call
>> this passing in an existing backlight-device (with its sysfs interface
>> disabled). This either creates a singleton /sys/class/backlight/aggregate
>> device, or adds the passed in backlight to the existing singleton instance
>> if it already exists.
>>
>> This new driver always exposes a range of 0-255 to userspace. This acts
>> as a proxie for any backlight-devices registered to be part of
>> the aggregate, forwarding any brightness set calls to all backlights,
>> scaled to their actual range. For reads this will report the last set
>> brightness value (starting with the value of the first registered
>> backlight-device).
>>
>> 3. Add a new nvidia_wmi_ec_and_native type to drivers/acpi/video_detect.c
>> for both DMI quirks and commandline handling.
>>
>
> So by default both the native and GPU drivers would register a "normal"
> backlight handler, and if the "both" quirk is set (or if requested via
> kernel command line) they'll register with the aggregate device?
>
> Would it make sense to make this more generic, with a parameter which
> can be set via command line or quirks for which backlight devices to
> aggregate? And then maybe instead of a new "nvidia_wmi_ec_and_native"
> backlight type in video_detect.c, it could be called "aggregate" or
> something else along those lines, used in combination with the list of
> backlight types to aggregate.
>
> Have we seen systems where both the iGPU and dGPU register their own
> native handlers? I vaguely recall seeing such a system, but I do not
> keep careful notes about this sort of thing, so I'm not certain. If
> there are indeed such systems, then "native" might not be specific
> enough, and it may be necessary to explicitly name backlight drivers
> individually in order to aggregate them.
>>
>> 4. Modify acpi_video_backlight_use_native() to also return true if
>> the __acpi_video_get_backlight_type() call there returns the new
>> acpi_backlight_nvidia_wmi_ec_and_native.
>
>> 5. Add a new devm_backlight_device_register_native() helper which
>> calls __acpi_video_get_backlight_type(true, NULL) and if that returns
>> the new nvidia_wmi_ec_and_native type then registers the passed in
>> backlight with the flag to not register a sysfs class interface and
>> then on success calls the new devm_backlight_aggregate_register_or_add()
>> with the just registered backlight device; and if the returned type
>> instead is acpi_backlight_native register the passed in backlight
>> normally through devm_backlight_device_register()
>>
>> 5. Modify the i915 and amdgpu drivers to use the new
>> devm_backlight_device_register_native() helper. Since this new helper
>> checks the backlight-type itself, drop acpi_video_backlight_use_native()
>> checks *if* the registration is the only thing guarded by that check.
>>
>> 6. drivers/platform/x86/nvidia-wmi-ec-backlight.c to not return
>> early from probe when acpi_video_get_backlight_type() returns
>> the new nvidia_wmi_ec_and_native type and for that type make it
>> registers its backlight with the flag to not register a sysfs class
>> interface and then on success calls the new
>> devm_backlight_aggregate_register_or_add().
>>
>
> There still isn't anything tying a particular sysfs backlight interface
> node to a specific display panel, right? Is there a plan to eventually
> support this? How would this interact with that plan? I'm just a little
> worried about designing ourselves into a corner that makes things harder
> to untangle individual devices later if the need arises.
Good point. I think it would be better if the GPU drivers themself
figure out if a given DRM connector belongs to the internal panel.
They could then register with a notifier that notifies the WMI driver
whenever the "official" backlight interface was changed to update the EC
state as needed.
If only the Nvidia GPU is supposed to interact with this WMI device,
then we could implement this as a private interface inside nova/noveau.
Otherwise we might need to come up with a more generic API.
Thanks,
Armin Wolf
>> Regards,
>>
>> Hans
>>
>
^ permalink raw reply
* Re: [PATCH] staging: sm750fb: add const to g_fbmode array
From: Ahmet Sezgin Duran @ 2026-05-06 10:36 UTC (permalink / raw)
To: Chaitanya Sabnis
Cc: sudipm.mukherjee, teddy.wang, gregkh, linux-fbdev, linux-staging,
linux-kernel
In-Reply-To: <CABjkosGtM-bju-gn9QtBfOMKMUsoYFb22noWjELnNi6B_ZBQ3Q@mail.gmail.com>
On 5/6/26 10:14 AM, Chaitanya Sabnis wrote:
> On Wed, May 6, 2026 at 11:57 AM Ahmet Sezgin Duran ahmet@sezginduran.net wrote:
>
> Did you compile these changes?
>
> Yes, I have verified the changes by compiling the driver with: make
> M=drivers/staging/sm750fb/
>
> The build completed successfully without errors.
>
> Regards,
> Chaitanya
Are you sure that you had enabled the module? When I apply and try to
compile your patch, I get these errors:
>
> CC [M] drivers/staging/sm750fb/sm750.o
> drivers/staging/sm750fb/sm750.c: In function ‘lynxfb_set_fbinfo’:
> drivers/staging/sm750fb/sm750.c:785:33: error: assignment of
read-only location ‘g_fbmode[index]’
> 785 | g_fbmode[index] = g_def_fbmode;
> | ^
> drivers/staging/sm750fb/sm750.c:787:41: error: assignment of
read-only location ‘g_fbmode[index]’
> 787 | g_fbmode[index] = g_fbmode[0];
> | ^
> drivers/staging/sm750fb/sm750.c: In function ‘sm750fb_setup’:
> drivers/staging/sm750fb/sm750.c:896:45: error: assignment of
read-only location ‘g_fbmode[0]’
> 896 | g_fbmode[0] = opt;
> | ^
> drivers/staging/sm750fb/sm750.c:900:45: error: assignment of
read-only location ‘g_fbmode[1]’
> 900 | g_fbmode[1] = opt;
> | ^
Regards,
Ahmet Sezgin Duran
^ permalink raw reply
* Re: [PATCH] staging: sm750fb: add const to g_fbmode array
From: Chaitanya Sabnis @ 2026-05-06 10:44 UTC (permalink / raw)
To: Ahmet Sezgin Duran
Cc: sudipm.mukherjee, teddy.wang, gregkh, linux-fbdev, linux-staging,
linux-kernel
In-Reply-To: <5113f014-f0fb-406a-9b3c-725acff62c9f@sezginduran.net>
On Wed, May 6, 2026 Ahmet Sezgin Duran wrote:
Are you sure that you had enabled the module? When I apply and try to
compile your patch, I get these errors:
Hi Ahmet,
You are completely right, and I apologize. I fell into the trap of
running make M=drivers/staging/sm750fb/ without verifying that
CONFIG_FB_SM750 was actually enabled in my .config first. My local
build silently skipped the compilation, which led me to falsely
believe the syntax was valid.
Looking at the errors you provided, it is clear that g_fbmode is
dynamically assigned during module setup (lines 896, 900), meaning the
checkpatch suggestion to make it const conflicts with the driver's
logic.
Please drop this patch. I will ensure my .config is properly set to
build the specific modules I am touching before submitting in the
future.
Thank you for catching this and for your time reviewing it.
Regards,
Chaitanya
On Wed, May 6, 2026 at 4:06 PM Ahmet Sezgin Duran <ahmet@sezginduran.net> wrote:
>
> On 5/6/26 10:14 AM, Chaitanya Sabnis wrote:
> > On Wed, May 6, 2026 at 11:57 AM Ahmet Sezgin Duran ahmet@sezginduran.net wrote:
> >
> > Did you compile these changes?
> >
> > Yes, I have verified the changes by compiling the driver with: make
> > M=drivers/staging/sm750fb/
> >
> > The build completed successfully without errors.
> >
> > Regards,
> > Chaitanya
>
> Are you sure that you had enabled the module? When I apply and try to
> compile your patch, I get these errors:
>
> >
> > CC [M] drivers/staging/sm750fb/sm750.o
> > drivers/staging/sm750fb/sm750.c: In function ‘lynxfb_set_fbinfo’:
> > drivers/staging/sm750fb/sm750.c:785:33: error: assignment of
> read-only location ‘g_fbmode[index]’
> > 785 | g_fbmode[index] = g_def_fbmode;
> > | ^
> > drivers/staging/sm750fb/sm750.c:787:41: error: assignment of
> read-only location ‘g_fbmode[index]’
> > 787 | g_fbmode[index] = g_fbmode[0];
> > | ^
> > drivers/staging/sm750fb/sm750.c: In function ‘sm750fb_setup’:
> > drivers/staging/sm750fb/sm750.c:896:45: error: assignment of
> read-only location ‘g_fbmode[0]’
> > 896 | g_fbmode[0] = opt;
> > | ^
> > drivers/staging/sm750fb/sm750.c:900:45: error: assignment of
> read-only location ‘g_fbmode[1]’
> > 900 | g_fbmode[1] = opt;
> > | ^
>
> Regards,
> Ahmet Sezgin Duran
^ permalink raw reply
* Re: [PATCH v2 0/2] Remove redundant X86 dependency for the cgbc backlight driver
From: Lee Jones @ 2026-05-07 13:25 UTC (permalink / raw)
To: Lee Jones, Daniel Thompson, Jingoo Han, Helge Deller,
Thomas Richard
Cc: Thomas Petazzoni, dri-devel, linux-fbdev, linux-kernel
In-Reply-To: <20260427-backlight-cgbc-remove-x86-dependency-v2-0-da9f2375a34a@bootlin.com>
On Mon, 27 Apr 2026 11:40:32 +0200, Thomas Richard wrote:
> For this second iteration, I just added Daniel's RB tags.
Applied, thanks!
[1/2] backlight: cgbc: Remove redundant X86 dependency
commit: db8e26c435698222b333cafcbc043dfdf083d591
[2/2] MAINTAINERS: Add cgbc backlight driver
commit: acea35b567d0f610d533ca661f4106ac12583f78
--
Lee Jones [李琼斯]
^ permalink raw reply
* Re: [PATCH] video: fbdev: remove Hercules monochrome ISA graphics adapter driver
From: Thomas Zimmermann @ 2026-05-08 12:08 UTC (permalink / raw)
To: Ethan Nelson-Moore, linux-fbdev
Cc: Ferenc Bakonyi, Helge Deller, Jakub Kicinski, Andrew Morton,
Namjae Jeon, Hisam Mehboob, Martin Kepplinger-Novaković,
Diego Viola, Wei Liu, Prasanna Kumar T S M, robgithub,
Hardik Phalet
In-Reply-To: <20260503045653.33522-1-enelsonmoore@gmail.com>
Hi
Am 03.05.26 um 06:56 schrieb Ethan Nelson-Moore:
> The hgafb supports graphics adapters compatible with the Hercules
> adapter from 1984. These were ISA cards or onboard devices that
> supported monochrome 720x348 graphics. This driver was created in 1999
> by Ferenc Bakonyi. In the entire Git history (since Linux 2.6.12-rc2),
> there has only been one commit in 2010 which indicated that the driver
> was in use, commit 529ed806d454 ("video: Fix the HGA framebuffer
> driver"). The commit message states:
> Only tested with fbcon, since most fbdev-based software appears
> to only support 12bpp and up. It does not appear that this driver has
> worked for at least the entire 2.6.x series, perhaps since 2002.
> Given the age and limited capabilities of the hardware and the lack of
> users, remove this driver and move the former maintainer to CREDITS.
>
> Signed-off-by: Ethan Nelson-Moore <enelsonmoore@gmail.com>
FWIW
Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
> ---
> CREDITS | 3 +
> MAINTAINERS | 7 -
> drivers/video/fbdev/Kconfig | 13 -
> drivers/video/fbdev/Makefile | 1 -
> drivers/video/fbdev/hgafb.c | 685 -----------------------------------
> 5 files changed, 3 insertions(+), 706 deletions(-)
> delete mode 100644 drivers/video/fbdev/hgafb.c
>
> diff --git a/CREDITS b/CREDITS
> index 17962bdd6dbd..59d5de3eeb5b 100644
> --- a/CREDITS
> +++ b/CREDITS
> @@ -197,6 +197,9 @@ S: Hauptstrasse 19
> S: 79837 St. Blasien
> S: Germany
>
> +N: Ferenc Bakonyi
> +D: Hercules graphics adapter framebuffer driver
> +
> N: Krishna Balasubramanian
> E: balasub@cis.ohio-state.edu
> D: Wrote SYS V IPC (part of standard kernel since 0.99.10)
> diff --git a/MAINTAINERS b/MAINTAINERS
> index 882214b0e7db..3194befa6a13 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -11373,13 +11373,6 @@ F: Documentation/filesystems/hfsplus.rst
> F: fs/hfsplus/
> F: include/linux/hfs_common.h
>
> -HGA FRAMEBUFFER DRIVER
> -M: Ferenc Bakonyi <fero@drama.obuda.kando.hu>
> -L: linux-nvidia@lists.surfsouth.com
> -S: Maintained
> -W: http://drama.obuda.kando.hu/~fero/cgi-bin/hgafb.shtml
> -F: drivers/video/fbdev/hgafb.c
> -
> HIBERNATION (aka Software Suspend, aka swsusp)
> M: "Rafael J. Wysocki" <rafael@kernel.org>
> R: Pavel Machek <pavel@kernel.org>
> diff --git a/drivers/video/fbdev/Kconfig b/drivers/video/fbdev/Kconfig
> index 1c73d560f196..085d3a202148 100644
> --- a/drivers/video/fbdev/Kconfig
> +++ b/drivers/video/fbdev/Kconfig
> @@ -453,19 +453,6 @@ config FB_N411
> This enables support for the Apollo display controller in its
> Hecuba form using the n411 devkit.
>
> -config FB_HGA
> - tristate "Hercules mono graphics support"
> - depends on FB && X86
> - select FB_IOMEM_FOPS
> - help
> - Say Y here if you have a Hercules mono graphics card.
> -
> - To compile this driver as a module, choose M here: the
> - module will be called hgafb.
> -
> - As this card technology is at least 25 years old,
> - most people will answer N here.
> -
> config FB_GBE
> bool "SGI Graphics Backend frame buffer support"
> depends on (FB = y) && HAS_IOMEM
> diff --git a/drivers/video/fbdev/Makefile b/drivers/video/fbdev/Makefile
> index 36a18d958ba0..0b17c878154d 100644
> --- a/drivers/video/fbdev/Makefile
> +++ b/drivers/video/fbdev/Makefile
> @@ -59,7 +59,6 @@ obj-$(CONFIG_FB_ATARI) += atafb.o c2p_iplan2.o atafb_mfb.o \
> obj-$(CONFIG_FB_MAC) += macfb.o
> obj-$(CONFIG_FB_HECUBA) += hecubafb.o
> obj-$(CONFIG_FB_N411) += n411.o
> -obj-$(CONFIG_FB_HGA) += hgafb.o
> obj-$(CONFIG_FB_XVR500) += sunxvr500.o
> obj-$(CONFIG_FB_XVR2500) += sunxvr2500.o
> obj-$(CONFIG_FB_XVR1000) += sunxvr1000.o
> diff --git a/drivers/video/fbdev/hgafb.c b/drivers/video/fbdev/hgafb.c
> deleted file mode 100644
> index d32fd1c5217c..000000000000
> --- a/drivers/video/fbdev/hgafb.c
> +++ /dev/null
> @@ -1,685 +0,0 @@
> -/*
> - * linux/drivers/video/hgafb.c -- Hercules graphics adaptor frame buffer device
> - *
> - * Created 25 Nov 1999 by Ferenc Bakonyi (fero@drama.obuda.kando.hu)
> - * Based on skeletonfb.c by Geert Uytterhoeven and
> - * mdacon.c by Andrew Apted
> - *
> - * History:
> - *
> - * - Revision 0.1.8 (23 Oct 2002): Ported to new framebuffer api.
> - *
> - * - Revision 0.1.7 (23 Jan 2001): fix crash resulting from MDA only cards
> - * being detected as Hercules. (Paul G.)
> - * - Revision 0.1.6 (17 Aug 2000): new style structs
> - * documentation
> - * - Revision 0.1.5 (13 Mar 2000): spinlocks instead of saveflags();cli();etc
> - * minor fixes
> - * - Revision 0.1.4 (24 Jan 2000): fixed a bug in hga_card_detect() for
> - * HGA-only systems
> - * - Revision 0.1.3 (22 Jan 2000): modified for the new fb_info structure
> - * screen is cleared after rmmod
> - * virtual resolutions
> - * module parameter 'nologo={0|1}'
> - * the most important: boot logo :)
> - * - Revision 0.1.0 (6 Dec 1999): faster scrolling and minor fixes
> - * - First release (25 Nov 1999)
> - *
> - * This file is subject to the terms and conditions of the GNU General Public
> - * License. See the file COPYING in the main directory of this archive
> - * for more details.
> - */
> -
> -#include <linux/module.h>
> -#include <linux/kernel.h>
> -#include <linux/errno.h>
> -#include <linux/spinlock.h>
> -#include <linux/string.h>
> -#include <linux/mm.h>
> -#include <linux/delay.h>
> -#include <linux/fb.h>
> -#include <linux/init.h>
> -#include <linux/ioport.h>
> -#include <linux/platform_device.h>
> -#include <asm/io.h>
> -#include <asm/vga.h>
> -
> -#if 0
> -#define DPRINTK(args...) printk(KERN_DEBUG __FILE__": " ##args)
> -#else
> -#define DPRINTK(args...)
> -#endif
> -
> -#if 0
> -#define CHKINFO(ret) if (info != &fb_info) { printk(KERN_DEBUG __FILE__": This should never happen, line:%d \n", __LINE__); return ret; }
> -#else
> -#define CHKINFO(ret)
> -#endif
> -
> -/* Description of the hardware layout */
> -
> -static void __iomem *hga_vram; /* Base of video memory */
> -static unsigned long hga_vram_len; /* Size of video memory */
> -
> -#define HGA_ROWADDR(row) ((row%4)*8192 + (row>>2)*90)
> -#define HGA_TXT 0
> -#define HGA_GFX 1
> -
> -static inline u8 __iomem * rowaddr(struct fb_info *info, u_int row)
> -{
> - return info->screen_base + HGA_ROWADDR(row);
> -}
> -
> -static int hga_mode = -1; /* 0 = txt, 1 = gfx mode */
> -
> -static enum { TYPE_HERC, TYPE_HERCPLUS, TYPE_HERCCOLOR } hga_type;
> -static char *hga_type_name;
> -
> -#define HGA_INDEX_PORT 0x3b4 /* Register select port */
> -#define HGA_VALUE_PORT 0x3b5 /* Register value port */
> -#define HGA_MODE_PORT 0x3b8 /* Mode control port */
> -#define HGA_STATUS_PORT 0x3ba /* Status and Config port */
> -#define HGA_GFX_PORT 0x3bf /* Graphics control port */
> -
> -/* HGA register values */
> -
> -#define HGA_CURSOR_BLINKING 0x00
> -#define HGA_CURSOR_OFF 0x20
> -#define HGA_CURSOR_SLOWBLINK 0x60
> -
> -#define HGA_MODE_GRAPHICS 0x02
> -#define HGA_MODE_VIDEO_EN 0x08
> -#define HGA_MODE_BLINK_EN 0x20
> -#define HGA_MODE_GFX_PAGE1 0x80
> -
> -#define HGA_STATUS_HSYNC 0x01
> -#define HGA_STATUS_VSYNC 0x80
> -#define HGA_STATUS_VIDEO 0x08
> -
> -#define HGA_CONFIG_COL132 0x08
> -#define HGA_GFX_MODE_EN 0x01
> -#define HGA_GFX_PAGE_EN 0x02
> -
> -/* Global locks */
> -
> -static DEFINE_SPINLOCK(hga_reg_lock);
> -
> -/* Framebuffer driver structures */
> -
> -static const struct fb_var_screeninfo hga_default_var = {
> - .xres = 720,
> - .yres = 348,
> - .xres_virtual = 720,
> - .yres_virtual = 348,
> - .bits_per_pixel = 1,
> - .red = {0, 1, 0},
> - .green = {0, 1, 0},
> - .blue = {0, 1, 0},
> - .transp = {0, 0, 0},
> - .height = -1,
> - .width = -1,
> -};
> -
> -static struct fb_fix_screeninfo hga_fix = {
> - .id = "HGA",
> - .type = FB_TYPE_PACKED_PIXELS, /* (not sure) */
> - .visual = FB_VISUAL_MONO10,
> - .xpanstep = 8,
> - .ypanstep = 8,
> - .line_length = 90,
> - .accel = FB_ACCEL_NONE
> -};
> -
> -/* Don't assume that tty1 will be the initial current console. */
> -static int release_io_port = 0;
> -static int release_io_ports = 0;
> -static bool nologo = 0;
> -
> -/* -------------------------------------------------------------------------
> - *
> - * Low level hardware functions
> - *
> - * ------------------------------------------------------------------------- */
> -
> -static void write_hga_b(unsigned int val, unsigned char reg)
> -{
> - outb_p(reg, HGA_INDEX_PORT);
> - outb_p(val, HGA_VALUE_PORT);
> -}
> -
> -static void write_hga_w(unsigned int val, unsigned char reg)
> -{
> - outb_p(reg, HGA_INDEX_PORT); outb_p(val >> 8, HGA_VALUE_PORT);
> - outb_p(reg+1, HGA_INDEX_PORT); outb_p(val & 0xff, HGA_VALUE_PORT);
> -}
> -
> -static int test_hga_b(unsigned char val, unsigned char reg)
> -{
> - outb_p(reg, HGA_INDEX_PORT);
> - outb (val, HGA_VALUE_PORT);
> - udelay(20); val = (inb_p(HGA_VALUE_PORT) == val);
> - return val;
> -}
> -
> -static void hga_clear_screen(void)
> -{
> - unsigned char fillchar = 0xbf; /* magic */
> - unsigned long flags;
> -
> - spin_lock_irqsave(&hga_reg_lock, flags);
> - if (hga_mode == HGA_TXT)
> - fillchar = ' ';
> - else if (hga_mode == HGA_GFX)
> - fillchar = 0x00;
> - spin_unlock_irqrestore(&hga_reg_lock, flags);
> - if (fillchar != 0xbf)
> - memset_io(hga_vram, fillchar, hga_vram_len);
> -}
> -
> -static void hga_txt_mode(void)
> -{
> - unsigned long flags;
> -
> - spin_lock_irqsave(&hga_reg_lock, flags);
> - outb_p(HGA_MODE_VIDEO_EN | HGA_MODE_BLINK_EN, HGA_MODE_PORT);
> - outb_p(0x00, HGA_GFX_PORT);
> - outb_p(0x00, HGA_STATUS_PORT);
> -
> - write_hga_b(0x61, 0x00); /* horizontal total */
> - write_hga_b(0x50, 0x01); /* horizontal displayed */
> - write_hga_b(0x52, 0x02); /* horizontal sync pos */
> - write_hga_b(0x0f, 0x03); /* horizontal sync width */
> -
> - write_hga_b(0x19, 0x04); /* vertical total */
> - write_hga_b(0x06, 0x05); /* vertical total adjust */
> - write_hga_b(0x19, 0x06); /* vertical displayed */
> - write_hga_b(0x19, 0x07); /* vertical sync pos */
> -
> - write_hga_b(0x02, 0x08); /* interlace mode */
> - write_hga_b(0x0d, 0x09); /* maximum scanline */
> - write_hga_b(0x0c, 0x0a); /* cursor start */
> - write_hga_b(0x0d, 0x0b); /* cursor end */
> -
> - write_hga_w(0x0000, 0x0c); /* start address */
> - write_hga_w(0x0000, 0x0e); /* cursor location */
> -
> - hga_mode = HGA_TXT;
> - spin_unlock_irqrestore(&hga_reg_lock, flags);
> -}
> -
> -static void hga_gfx_mode(void)
> -{
> - unsigned long flags;
> -
> - spin_lock_irqsave(&hga_reg_lock, flags);
> - outb_p(0x00, HGA_STATUS_PORT);
> - outb_p(HGA_GFX_MODE_EN, HGA_GFX_PORT);
> - outb_p(HGA_MODE_VIDEO_EN | HGA_MODE_GRAPHICS, HGA_MODE_PORT);
> -
> - write_hga_b(0x35, 0x00); /* horizontal total */
> - write_hga_b(0x2d, 0x01); /* horizontal displayed */
> - write_hga_b(0x2e, 0x02); /* horizontal sync pos */
> - write_hga_b(0x07, 0x03); /* horizontal sync width */
> -
> - write_hga_b(0x5b, 0x04); /* vertical total */
> - write_hga_b(0x02, 0x05); /* vertical total adjust */
> - write_hga_b(0x57, 0x06); /* vertical displayed */
> - write_hga_b(0x57, 0x07); /* vertical sync pos */
> -
> - write_hga_b(0x02, 0x08); /* interlace mode */
> - write_hga_b(0x03, 0x09); /* maximum scanline */
> - write_hga_b(0x00, 0x0a); /* cursor start */
> - write_hga_b(0x00, 0x0b); /* cursor end */
> -
> - write_hga_w(0x0000, 0x0c); /* start address */
> - write_hga_w(0x0000, 0x0e); /* cursor location */
> -
> - hga_mode = HGA_GFX;
> - spin_unlock_irqrestore(&hga_reg_lock, flags);
> -}
> -
> -static void hga_show_logo(struct fb_info *info)
> -{
> -/*
> - void __iomem *dest = hga_vram;
> - char *logo = linux_logo_bw;
> - int x, y;
> -
> - for (y = 134; y < 134 + 80 ; y++) * this needs some cleanup *
> - for (x = 0; x < 10 ; x++)
> - writeb(~*(logo++),(dest + HGA_ROWADDR(y) + x + 40));
> -*/
> -}
> -
> -static void hga_pan(unsigned int xoffset, unsigned int yoffset)
> -{
> - unsigned int base;
> - unsigned long flags;
> -
> - base = (yoffset / 8) * 90 + xoffset;
> - spin_lock_irqsave(&hga_reg_lock, flags);
> - write_hga_w(base, 0x0c); /* start address */
> - spin_unlock_irqrestore(&hga_reg_lock, flags);
> - DPRINTK("hga_pan: base:%d\n", base);
> -}
> -
> -static void hga_blank(int blank_mode)
> -{
> - unsigned long flags;
> -
> - spin_lock_irqsave(&hga_reg_lock, flags);
> - if (blank_mode) {
> - outb_p(0x00, HGA_MODE_PORT); /* disable video */
> - } else {
> - outb_p(HGA_MODE_VIDEO_EN | HGA_MODE_GRAPHICS, HGA_MODE_PORT);
> - }
> - spin_unlock_irqrestore(&hga_reg_lock, flags);
> -}
> -
> -static int hga_card_detect(struct platform_device *pdev)
> -{
> - int count = 0;
> - void __iomem *p, *q;
> - unsigned short p_save, q_save;
> -
> - hga_vram_len = 0x08000;
> -
> - if (!devm_request_mem_region(&pdev->dev, 0xb0000, hga_vram_len, "hgafb")) {
> - dev_err(&pdev->dev, "cannot reserve video memory at 0xb0000\n");
> - return -EBUSY;
> - }
> -
> - hga_vram = ioremap(0xb0000, hga_vram_len);
> - if (!hga_vram)
> - return -ENOMEM;
> -
> - if (request_region(0x3b0, 12, "hgafb"))
> - release_io_ports = 1;
> - if (request_region(0x3bf, 1, "hgafb"))
> - release_io_port = 1;
> -
> - /* do a memory check */
> -
> - p = hga_vram;
> - q = hga_vram + 0x01000;
> -
> - p_save = readw(p); q_save = readw(q);
> -
> - writew(0xaa55, p); if (readw(p) == 0xaa55) count++;
> - writew(0x55aa, p); if (readw(p) == 0x55aa) count++;
> - writew(p_save, p);
> -
> - if (count != 2)
> - goto error;
> -
> - /* Ok, there is definitely a card registering at the correct
> - * memory location, so now we do an I/O port test.
> - */
> -
> - if (!test_hga_b(0x66, 0x0f)) /* cursor low register */
> - goto error;
> -
> - if (!test_hga_b(0x99, 0x0f)) /* cursor low register */
> - goto error;
> -
> - /* See if the card is a Hercules, by checking whether the vsync
> - * bit of the status register is changing. This test lasts for
> - * approximately 1/10th of a second.
> - */
> -
> - p_save = q_save = inb_p(HGA_STATUS_PORT) & HGA_STATUS_VSYNC;
> -
> - for (count=0; count < 50000 && p_save == q_save; count++) {
> - q_save = inb(HGA_STATUS_PORT) & HGA_STATUS_VSYNC;
> - udelay(2);
> - }
> -
> - if (p_save == q_save)
> - goto error;
> -
> - switch (inb_p(HGA_STATUS_PORT) & 0x70) {
> - case 0x10:
> - hga_type = TYPE_HERCPLUS;
> - hga_type_name = "HerculesPlus";
> - break;
> - case 0x50:
> - hga_type = TYPE_HERCCOLOR;
> - hga_type_name = "HerculesColor";
> - break;
> - default:
> - hga_type = TYPE_HERC;
> - hga_type_name = "Hercules";
> - break;
> - }
> - return 0;
> -error:
> - if (release_io_ports)
> - release_region(0x3b0, 12);
> - if (release_io_port)
> - release_region(0x3bf, 1);
> -
> - iounmap(hga_vram);
> -
> - pr_err("hgafb: HGA card not detected.\n");
> -
> - return -EINVAL;
> -}
> -
> -/**
> - * hgafb_open - open the framebuffer device
> - * @info: pointer to fb_info object containing info for current hga board
> - * @init: open by console system or userland.
> - *
> - * Returns: %0
> - */
> -
> -static int hgafb_open(struct fb_info *info, int init)
> -{
> - hga_gfx_mode();
> - hga_clear_screen();
> - if (!nologo) hga_show_logo(info);
> - return 0;
> -}
> -
> -/**
> - * hgafb_release - open the framebuffer device
> - * @info: pointer to fb_info object containing info for current hga board
> - * @init: open by console system or userland.
> - *
> - * Returns: %0
> - */
> -
> -static int hgafb_release(struct fb_info *info, int init)
> -{
> - hga_txt_mode();
> - hga_clear_screen();
> - return 0;
> -}
> -
> -/**
> - * hgafb_setcolreg - set color registers
> - * @regno:register index to set
> - * @red:red value, unused
> - * @green:green value, unused
> - * @blue:blue value, unused
> - * @transp:transparency value, unused
> - * @info:unused
> - *
> - * This callback function is used to set the color registers of a HGA
> - * board. Since we have only two fixed colors only @regno is checked.
> - * A zero is returned on success and 1 for failure.
> - *
> - * Returns: %0
> - */
> -
> -static int hgafb_setcolreg(u_int regno, u_int red, u_int green, u_int blue,
> - u_int transp, struct fb_info *info)
> -{
> - if (regno > 1)
> - return 1;
> - return 0;
> -}
> -
> -/**
> - * hgafb_pan_display - pan or wrap the display
> - * @var:contains new xoffset, yoffset and vmode values
> - * @info:pointer to fb_info object containing info for current hga board
> - *
> - * This function looks only at xoffset, yoffset and the %FB_VMODE_YWRAP
> - * flag in @var. If input parameters are correct it calls hga_pan() to
> - * program the hardware. @info->var is updated to the new values.
> - *
> - * Returns: %0 on success or %-EINVAL for failure.
> - */
> -
> -static int hgafb_pan_display(struct fb_var_screeninfo *var,
> - struct fb_info *info)
> -{
> - if (var->vmode & FB_VMODE_YWRAP) {
> - if (var->yoffset >= info->var.yres_virtual ||
> - var->xoffset)
> - return -EINVAL;
> - } else {
> - if (var->xoffset + info->var.xres > info->var.xres_virtual
> - || var->yoffset + info->var.yres > info->var.yres_virtual
> - || var->yoffset % 8)
> - return -EINVAL;
> - }
> -
> - hga_pan(var->xoffset, var->yoffset);
> - return 0;
> -}
> -
> -/**
> - * hgafb_blank - (un)blank the screen
> - * @blank_mode:blanking method to use
> - * @info:unused
> - *
> - * Blank the screen if blank_mode != 0, else unblank.
> - * Implements VESA suspend and powerdown modes on hardware that supports
> - * disabling hsync/vsync:
> - * @blank_mode == 2 means suspend vsync,
> - * @blank_mode == 3 means suspend hsync,
> - * @blank_mode == 4 means powerdown.
> - *
> - * Returns: %0
> - */
> -
> -static int hgafb_blank(int blank_mode, struct fb_info *info)
> -{
> - hga_blank(blank_mode);
> - return 0;
> -}
> -
> -/*
> - * Accel functions
> - */
> -static void hgafb_fillrect(struct fb_info *info, const struct fb_fillrect *rect)
> -{
> - u_int rows, y;
> - u8 __iomem *dest;
> -
> - y = rect->dy;
> -
> - for (rows = rect->height; rows--; y++) {
> - dest = rowaddr(info, y) + (rect->dx >> 3);
> - switch (rect->rop) {
> - case ROP_COPY:
> - memset_io(dest, rect->color, (rect->width >> 3));
> - break;
> - case ROP_XOR:
> - fb_writeb(~(fb_readb(dest)), dest);
> - break;
> - }
> - }
> -}
> -
> -static void hgafb_copyarea(struct fb_info *info, const struct fb_copyarea *area)
> -{
> - u_int rows, y1, y2;
> - u8 __iomem *src;
> - u8 __iomem *dest;
> -
> - if (area->dy <= area->sy) {
> - y1 = area->sy;
> - y2 = area->dy;
> -
> - for (rows = area->height; rows--; ) {
> - src = rowaddr(info, y1) + (area->sx >> 3);
> - dest = rowaddr(info, y2) + (area->dx >> 3);
> - memmove(dest, src, (area->width >> 3));
> - y1++;
> - y2++;
> - }
> - } else {
> - y1 = area->sy + area->height - 1;
> - y2 = area->dy + area->height - 1;
> -
> - for (rows = area->height; rows--;) {
> - src = rowaddr(info, y1) + (area->sx >> 3);
> - dest = rowaddr(info, y2) + (area->dx >> 3);
> - memmove(dest, src, (area->width >> 3));
> - y1--;
> - y2--;
> - }
> - }
> -}
> -
> -static void hgafb_imageblit(struct fb_info *info, const struct fb_image *image)
> -{
> - u8 __iomem *dest;
> - u8 *cdat = (u8 *) image->data;
> - u_int rows, y = image->dy;
> - u_int x;
> - u8 d;
> -
> - for (rows = image->height; rows--; y++) {
> - for (x = 0; x < image->width; x+= 8) {
> - d = *cdat++;
> - dest = rowaddr(info, y) + ((image->dx + x)>> 3);
> - fb_writeb(d, dest);
> - }
> - }
> -}
> -
> -static const struct fb_ops hgafb_ops = {
> - .owner = THIS_MODULE,
> - .fb_open = hgafb_open,
> - .fb_release = hgafb_release,
> - __FB_DEFAULT_IOMEM_OPS_RDWR,
> - .fb_setcolreg = hgafb_setcolreg,
> - .fb_pan_display = hgafb_pan_display,
> - .fb_blank = hgafb_blank,
> - .fb_fillrect = hgafb_fillrect,
> - .fb_copyarea = hgafb_copyarea,
> - .fb_imageblit = hgafb_imageblit,
> - __FB_DEFAULT_IOMEM_OPS_MMAP,
> -};
> -
> -/* ------------------------------------------------------------------------- *
> - *
> - * Functions in fb_info
> - *
> - * ------------------------------------------------------------------------- */
> -
> -/* ------------------------------------------------------------------------- */
> -
> - /*
> - * Initialization
> - */
> -
> -static int hgafb_probe(struct platform_device *pdev)
> -{
> - struct fb_info *info;
> - int ret;
> -
> - ret = hga_card_detect(pdev);
> - if (ret)
> - return ret;
> -
> - printk(KERN_INFO "hgafb: %s with %ldK of memory detected.\n",
> - hga_type_name, hga_vram_len/1024);
> -
> - info = framebuffer_alloc(0, &pdev->dev);
> - if (!info) {
> - iounmap(hga_vram);
> - return -ENOMEM;
> - }
> -
> - hga_fix.smem_start = (unsigned long)hga_vram;
> - hga_fix.smem_len = hga_vram_len;
> -
> - info->flags = FBINFO_HWACCEL_YPAN;
> - info->var = hga_default_var;
> - info->fix = hga_fix;
> - info->monspecs.hfmin = 0;
> - info->monspecs.hfmax = 0;
> - info->monspecs.vfmin = 10000;
> - info->monspecs.vfmax = 10000;
> - info->monspecs.dpms = 0;
> - info->fbops = &hgafb_ops;
> - info->screen_base = hga_vram;
> -
> - if (register_framebuffer(info) < 0) {
> - framebuffer_release(info);
> - iounmap(hga_vram);
> - return -EINVAL;
> - }
> -
> - fb_info(info, "%s frame buffer device\n", info->fix.id);
> - platform_set_drvdata(pdev, info);
> - return 0;
> -}
> -
> -static void hgafb_remove(struct platform_device *pdev)
> -{
> - struct fb_info *info = platform_get_drvdata(pdev);
> -
> - hga_txt_mode();
> - hga_clear_screen();
> -
> - if (info) {
> - unregister_framebuffer(info);
> - framebuffer_release(info);
> - }
> -
> - iounmap(hga_vram);
> -
> - if (release_io_ports)
> - release_region(0x3b0, 12);
> -
> - if (release_io_port)
> - release_region(0x3bf, 1);
> -}
> -
> -static struct platform_driver hgafb_driver = {
> - .probe = hgafb_probe,
> - .remove = hgafb_remove,
> - .driver = {
> - .name = "hgafb",
> - },
> -};
> -
> -static struct platform_device *hgafb_device;
> -
> -static int __init hgafb_init(void)
> -{
> - int ret;
> -
> - if (fb_get_options("hgafb", NULL))
> - return -ENODEV;
> -
> - ret = platform_driver_register(&hgafb_driver);
> -
> - if (!ret) {
> - hgafb_device = platform_device_register_simple("hgafb", 0, NULL, 0);
> -
> - if (IS_ERR(hgafb_device)) {
> - platform_driver_unregister(&hgafb_driver);
> - ret = PTR_ERR(hgafb_device);
> - }
> - }
> -
> - return ret;
> -}
> -
> -static void __exit hgafb_exit(void)
> -{
> - platform_device_unregister(hgafb_device);
> - platform_driver_unregister(&hgafb_driver);
> -}
> -
> -/* -------------------------------------------------------------------------
> - *
> - * Modularization
> - *
> - * ------------------------------------------------------------------------- */
> -
> -MODULE_AUTHOR("Ferenc Bakonyi <fero@drama.obuda.kando.hu>");
> -MODULE_DESCRIPTION("FBDev driver for Hercules Graphics Adaptor");
> -MODULE_LICENSE("GPL");
> -
> -module_param(nologo, bool, 0);
> -MODULE_PARM_DESC(nologo, "Disables startup logo if != 0 (default=0)");
> -module_init(hgafb_init);
> -module_exit(hgafb_exit);
--
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com
GF: Jochen Jaser, Andrew McDonald, Werner Knoblich, (HRB 36809, AG Nürnberg)
^ permalink raw reply
* [PATCH] fbdev: chipsfb: add missing MODULE_DESCRIPTION() macro
From: Rahman Mahmutović @ 2026-05-09 13:18 UTC (permalink / raw)
To: linux-fbdev; +Cc: deller, dri-devel, linux-kernel, Rahman Mahmutović
The chipsfb driver is missing the MODULE_DESCRIPTION macro which
is required for all kernel modules.
Assisted-by: Claude:claude-sonnet-4-6
Signed-off-by: Rahman Mahmutović <mahmutovicrahman5@gmail.com>
---
drivers/video/fbdev/chipsfb.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/video/fbdev/chipsfb.c b/drivers/video/fbdev/chipsfb.c
index 33caf0b99..946e30fcb 100644
--- a/drivers/video/fbdev/chipsfb.c
+++ b/drivers/video/fbdev/chipsfb.c
@@ -526,4 +526,5 @@ static void __exit chipsfb_exit(void)
pci_unregister_driver(&chipsfb_driver);
}
+MODULE_DESCRIPTION("Chips & Technologies 65550 frame buffer driver");
MODULE_LICENSE("GPL");
--
2.43.0
^ permalink raw reply related
* [PATCH] fbdev: sunxvr2500: replace printk with device-aware logging functions
From: Rahman Mahmutović @ 2026-05-09 13:57 UTC (permalink / raw)
To: linux-fbdev; +Cc: deller, dri-devel, linux-kernel, Rahman Mahmutović
Replace all printk() calls with appropriate device-aware logging
functions to properly associate log messages with the PCI device.
- Use pci_err() for errors where struct pci_dev is available
- Use pci_info() for info messages where struct pci_dev is available
- Use dev_err() for errors where only struct fb_info is available
Remove redundant 's3d:' prefix and pci_name() calls as device-aware
functions include device identification automatically.
Assisted-by: Claude:claude-sonnet-4-6
Signed-off-by: Rahman Mahmutović <mahmutovicrahman5@gmail.com>
---
drivers/video/fbdev/sunxvr2500.c | 19 +++++++------------
1 file changed, 7 insertions(+), 12 deletions(-)
diff --git a/drivers/video/fbdev/sunxvr2500.c b/drivers/video/fbdev/sunxvr2500.c
index 42426d09b..3a36e7524 100644
--- a/drivers/video/fbdev/sunxvr2500.c
+++ b/drivers/video/fbdev/sunxvr2500.c
@@ -38,8 +38,7 @@ static int s3d_get_props(struct s3d_info *sp)
sp->depth = of_getintprop_default(sp->of_node, "depth", 8);
if (!sp->width || !sp->height) {
- printk(KERN_ERR "s3d: Critical properties missing for %s\n",
- pci_name(sp->pdev));
+ pci_err(sp->pdev, "Critical properties missing\n");
return -EINVAL;
}
@@ -107,7 +106,7 @@ static int s3d_set_fbinfo(struct s3d_info *sp)
var->transp.length = 0;
if (fb_alloc_cmap(&info->cmap, 256, 0)) {
- printk(KERN_ERR "s3d: Cannot allocate color map.\n");
+ dev_err(info->dev, "Cannot allocate color map\n");
return -ENOMEM;
}
@@ -127,8 +126,7 @@ static int s3d_pci_register(struct pci_dev *pdev,
err = pci_enable_device(pdev);
if (err < 0) {
- printk(KERN_ERR "s3d: Cannot enable PCI device %s\n",
- pci_name(pdev));
+ pci_err(pdev, "Cannot enable PCI device\n");
goto err_out;
}
@@ -143,8 +141,7 @@ static int s3d_pci_register(struct pci_dev *pdev,
sp->pdev = pdev;
sp->of_node = pci_device_to_OF_node(pdev);
if (!sp->of_node) {
- printk(KERN_ERR "s3d: Cannot find OF node of %s\n",
- pci_name(pdev));
+ pci_err(pdev, "Cannot find OF node\n");
err = -ENODEV;
goto err_release_fb;
}
@@ -153,8 +150,7 @@ static int s3d_pci_register(struct pci_dev *pdev,
err = pci_request_region(pdev, 1, "s3d framebuffer");
if (err < 0) {
- printk("s3d: Cannot request region 1 for %s\n",
- pci_name(pdev));
+ pci_err(pdev, "Cannot request region 1\n");
goto err_release_fb;
}
@@ -194,12 +190,11 @@ static int s3d_pci_register(struct pci_dev *pdev,
pci_set_drvdata(pdev, info);
- printk("s3d: Found device at %s\n", pci_name(pdev));
+ pci_info(pdev, "Found device\n");
err = register_framebuffer(info);
if (err < 0) {
- printk(KERN_ERR "s3d: Could not register framebuffer %s\n",
- pci_name(pdev));
+ pci_err(pdev, "Could not register framebuffer\n");
goto err_unmap_fb;
}
--
2.43.0
^ permalink raw reply related
* [PATCH] staging: sm750fb: Add const to g_fbmode array
From: Alone @ 2026-05-09 16:40 UTC (permalink / raw)
To: Sudip Mukherjee, Teddy Wang, Greg Kroah-Hartman
Cc: linux-fbdev, linux-staging, linux-kernel, Chhabilal Dangal
From: Chhabilal Dangal <yogeshdangal66@gmail.com>
Add const qualifier to g_fbmode array since the array
itself is not modified after initialization.
Signed-off-by: Chhabilal Dangal <yogeshdangal66@gmail.com>
---
drivers/staging/sm750fb/sm750.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
index 9f3e3d37e..19c3da654 100644
--- a/drivers/staging/sm750fb/sm750.c
+++ b/drivers/staging/sm750fb/sm750.c
@@ -33,7 +33,7 @@
static int g_hwcursor = 1;
static int g_noaccel;
static int g_nomtrr;
-static const char *g_fbmode[] = {NULL, NULL};
+static const char * const g_fbmode[] = {NULL, NULL};
static const char *g_def_fbmode = "1024x768-32@60";
static char *g_settings;
static int g_dualview;
--
2.54.0
^ permalink raw reply related
* [PATCH] fbdev: make sh_mobile_lcdc independent of FB_DEVICE
From: Melih Emik @ 2026-05-09 18:27 UTC (permalink / raw)
To: Helge Deller, linux-fbdev, dri-devel
Cc: Thomas Zimmermann, Wei Liu, Prasanna Kumar T S M, Zsolt Kajtar,
Mukesh Rathor, linux-kernel
CONFIG_FB_DEVICE controls the fbdev character device interface. SH Mobile
LCDC does not need that interface to build framebuffer support. Tying the
driver option to FB_DEVICE unnecessarily prevents it from being enabled
where device node support is disabled.
Relax the Kconfig dependency so the driver can be built independently of
the fbdev device interface.
Signed-off-by: Melih Emik <melihemik@noirlang.tr>
---
drivers/video/fbdev/Kconfig | 1 -
drivers/video/fbdev/sh_mobile_lcdcfb.c | 6 ++++--
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/video/fbdev/Kconfig b/drivers/video/fbdev/Kconfig
index 085d3a202148..762c4369e00f 100644
--- a/drivers/video/fbdev/Kconfig
+++ b/drivers/video/fbdev/Kconfig
@@ -1521,7 +1521,6 @@ config FB_SH_MOBILE_LCDC
tristate "SuperH Mobile LCDC framebuffer support"
depends on FB && HAVE_CLK && HAS_IOMEM
depends on SUPERH || COMPILE_TEST
- depends on FB_DEVICE
depends on BACKLIGHT_CLASS_DEVICE
select FB_BACKLIGHT
select FB_DEFERRED_IO
diff --git a/drivers/video/fbdev/sh_mobile_lcdcfb.c b/drivers/video/fbdev/sh_mobile_lcdcfb.c
index 72969fe8e513..b522b76b402d 100644
--- a/drivers/video/fbdev/sh_mobile_lcdcfb.c
+++ b/drivers/video/fbdev/sh_mobile_lcdcfb.c
@@ -1511,7 +1511,7 @@ sh_mobile_lcdc_overlay_fb_unregister(struct sh_mobile_lcdc_overlay *ovl)
{
struct fb_info *info = ovl->info;
- if (info == NULL || info->dev == NULL)
+ if (!info || !refcount_read(&info->count))
return;
unregister_framebuffer(ovl->info);
@@ -1983,7 +1983,7 @@ static const struct fb_ops sh_mobile_lcdc_ops = {
static void
sh_mobile_lcdc_channel_fb_unregister(struct sh_mobile_lcdc_chan *ch)
{
- if (ch->info && ch->info->dev)
+ if (ch->info && refcount_read(&ch->info->count))
unregister_framebuffer(ch->info);
}
@@ -2640,7 +2640,9 @@ static int sh_mobile_lcdc_probe(struct platform_device *pdev)
static struct platform_driver sh_mobile_lcdc_driver = {
.driver = {
.name = "sh_mobile_lcdc_fb",
+#ifdef CONFIG_FB_DEVICE
.dev_groups = overlay_sysfs_groups,
+#endif
.pm = &sh_mobile_lcdc_dev_pm_ops,
},
.probe = sh_mobile_lcdc_probe,
--
2.54.0
^ permalink raw reply related
* [PATCH] ARM: mach-rpc: fix zImage build after recent font-related changes
From: Ethan Nelson-Moore @ 2026-05-10 2:39 UTC (permalink / raw)
To: linux-arm-kernel, linux-fbdev
Cc: Russell King, Ethan Nelson-Moore, Helge Deller, Thomas Zimmermann,
Kees Cook
The text display code used in the Risc PC kernel image decompression
code uses arch/arm/boot/compressed/font.c, which includes
lib/fonts/font_acorn_8x8.c, which further includes <linux/font.h>.
Since commit 97df8960240a ("lib/fonts: Provide helpers for calculating
glyph pitch and size") <linux/font.h> contains inline functions that
require __do_div64, which is not linked into the ARM kernel
decompressor. This makes Risc PC zImages fail to build.
Resolve this issue in the least intrusive way possible by preventing
the inclusion of <linux/font.h> (and the definition of a struct that
relies on it) when the decompressor is being built.
Fixes: 97df8960240a ("lib/fonts: Provide helpers for calculating glyph pitch and size")
Signed-off-by: Ethan Nelson-Moore <enelsonmoore@gmail.com>
---
arch/arm/boot/compressed/Makefile | 6 +++++-
lib/fonts/font_acorn_8x8.c | 2 ++
2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/arch/arm/boot/compressed/Makefile b/arch/arm/boot/compressed/Makefile
index a159120d1e42..0e198a6ce447 100644
--- a/arch/arm/boot/compressed/Makefile
+++ b/arch/arm/boot/compressed/Makefile
@@ -157,4 +157,8 @@ $(obj)/piggy_data: $(obj)/../Image FORCE
$(obj)/piggy.o: $(obj)/piggy_data
-CFLAGS_font.o := -Dstatic=
+# Defining _VIDEO_FONT_H prevents including <linux/font.h>, which contains
+# inline functions that require __do_div64, which is not linked into the
+# decompressor. OMIT_FONT_DESC is used in lib/fonts/font_acorn_8x8.c to omit the
+# definition of the font's font_desc structure, which requires <linux/font.h>.
+CFLAGS_font.o := -Dstatic= -D_VIDEO_FONT_H -DOMIT_FONT_DESC
diff --git a/lib/fonts/font_acorn_8x8.c b/lib/fonts/font_acorn_8x8.c
index 36c51016769d..6b5291c23fc8 100644
--- a/lib/fonts/font_acorn_8x8.c
+++ b/lib/fonts/font_acorn_8x8.c
@@ -265,6 +265,7 @@ static const struct font_data acorndata_8x8 = {
/* FF */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
} };
+#ifndef OMIT_FONT_DESC /* Used by arch/arm/boot/compressed/Makefile */
const struct font_desc font_acorn_8x8 = {
.idx = ACORN8x8_IDX,
.name = "Acorn8x8",
@@ -278,3 +279,4 @@ const struct font_desc font_acorn_8x8 = {
.pref = 0,
#endif
};
+#endif /* OMIT_FONT_DESC */
--
2.43.0
^ permalink raw reply related
* [PATCH] ARM: move Risc PC-specific <asm/hardware/iomd.h> header into mach-rpc
From: Ethan Nelson-Moore @ 2026-05-10 3:10 UTC (permalink / raw)
To: linux-arm-kernel, linux-i2c, linux-input, linux-fbdev
Cc: Russell King, Ethan Nelson-Moore, Andi Shyti, Dmitry Torokhov,
Helge Deller, Kees Cook
The <asm/hardware/iomd.h> header is specific to the IOMD chip used on
the Risc PC. Move it into mach-rpc to avoid polluting asm/hardware/
with machine-specific headers.
Also take the opportunity to remove a comment with the file path from
the header, which is bad style.
Signed-off-by: Ethan Nelson-Moore <enelsonmoore@gmail.com>
---
MAINTAINERS | 1 -
arch/arm/mach-rpc/dma.c | 2 +-
arch/arm/{include/asm/hardware => mach-rpc/include/mach}/iomd.h | 2 --
arch/arm/mach-rpc/irq.c | 2 +-
arch/arm/mach-rpc/riscpc.c | 2 +-
arch/arm/mach-rpc/time.c | 2 +-
drivers/i2c/busses/i2c-acorn.c | 2 +-
drivers/input/mouse/rpcmouse.c | 2 +-
drivers/input/serio/rpckbd.c | 2 +-
drivers/video/fbdev/acornfb.h | 2 +-
10 files changed, 8 insertions(+), 11 deletions(-)
rename arch/arm/{include/asm/hardware => mach-rpc/include/mach}/iomd.h (98%)
diff --git a/MAINTAINERS b/MAINTAINERS
index 211cc683e25b..6a1da8903c04 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3398,7 +3398,6 @@ M: Russell King <linux@armlinux.org.uk>
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
S: Maintained
W: http://www.armlinux.org.uk/
-F: arch/arm/include/asm/hardware/iomd.h
F: arch/arm/mach-rpc/
F: drivers/net/ethernet/8390/etherh.c
F: drivers/net/ethernet/i825xx/ether1*
diff --git a/arch/arm/mach-rpc/dma.c b/arch/arm/mach-rpc/dma.c
index 50e0f97afd75..717a81475670 100644
--- a/arch/arm/mach-rpc/dma.c
+++ b/arch/arm/mach-rpc/dma.c
@@ -20,7 +20,7 @@
#include <linux/uaccess.h>
#include <asm/mach/dma.h>
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
struct iomd_dma {
struct dma_struct dma;
diff --git a/arch/arm/include/asm/hardware/iomd.h b/arch/arm/mach-rpc/include/mach/iomd.h
similarity index 98%
rename from arch/arm/include/asm/hardware/iomd.h
rename to arch/arm/mach-rpc/include/mach/iomd.h
index e3f130345ebc..2a3f4a5f3fd9 100644
--- a/arch/arm/include/asm/hardware/iomd.h
+++ b/arch/arm/mach-rpc/include/mach/iomd.h
@@ -1,7 +1,5 @@
/* SPDX-License-Identifier: GPL-2.0-only */
/*
- * arch/arm/include/asm/hardware/iomd.h
- *
* Copyright (C) 1999 Russell King
*
* This file contains information out the IOMD ASIC used in the
diff --git a/arch/arm/mach-rpc/irq.c b/arch/arm/mach-rpc/irq.c
index e924c9b813ab..649d81874c86 100644
--- a/arch/arm/mach-rpc/irq.c
+++ b/arch/arm/mach-rpc/irq.c
@@ -4,7 +4,7 @@
#include <linux/io.h>
#include <asm/mach/irq.h>
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
#include <asm/irq.h>
#include <asm/fiq.h>
diff --git a/arch/arm/mach-rpc/riscpc.c b/arch/arm/mach-rpc/riscpc.c
index f70fb9c4b0cb..d068f5e4873d 100644
--- a/arch/arm/mach-rpc/riscpc.c
+++ b/arch/arm/mach-rpc/riscpc.c
@@ -22,7 +22,7 @@
#include <asm/elf.h>
#include <asm/mach-types.h>
#include <mach/hardware.h>
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
#include <asm/page.h>
#include <asm/domain.h>
#include <asm/setup.h>
diff --git a/arch/arm/mach-rpc/time.c b/arch/arm/mach-rpc/time.c
index ad93c4dfafcd..566113f9774f 100644
--- a/arch/arm/mach-rpc/time.c
+++ b/arch/arm/mach-rpc/time.c
@@ -17,7 +17,7 @@
#include <linux/io.h>
#include <mach/hardware.h>
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
#include <asm/mach/time.h>
diff --git a/drivers/i2c/busses/i2c-acorn.c b/drivers/i2c/busses/i2c-acorn.c
index 99b6b1c3fd9e..703b4a42f466 100644
--- a/drivers/i2c/busses/i2c-acorn.c
+++ b/drivers/i2c/busses/i2c-acorn.c
@@ -13,7 +13,7 @@
#include <linux/io.h>
#include <mach/hardware.h>
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
#define FORCE_ONES 0xdc
#define SCL 0x02
diff --git a/drivers/input/mouse/rpcmouse.c b/drivers/input/mouse/rpcmouse.c
index 6774029e0a1a..475c3ca22fd4 100644
--- a/drivers/input/mouse/rpcmouse.c
+++ b/drivers/input/mouse/rpcmouse.c
@@ -23,7 +23,7 @@
#include <mach/hardware.h>
#include <asm/irq.h>
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
MODULE_AUTHOR("Vojtech Pavlik, Russell King");
MODULE_DESCRIPTION("Acorn RiscPC mouse driver");
diff --git a/drivers/input/serio/rpckbd.c b/drivers/input/serio/rpckbd.c
index 4d817850ba3b..e452ad07e2fa 100644
--- a/drivers/input/serio/rpckbd.c
+++ b/drivers/input/serio/rpckbd.c
@@ -17,7 +17,7 @@
#include <linux/slab.h>
#include <mach/hardware.h>
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
MODULE_AUTHOR("Vojtech Pavlik, Russell King");
MODULE_DESCRIPTION("Acorn RiscPC PS/2 keyboard controller driver");
diff --git a/drivers/video/fbdev/acornfb.h b/drivers/video/fbdev/acornfb.h
index f8df4ecb4fd7..e65388587f80 100644
--- a/drivers/video/fbdev/acornfb.h
+++ b/drivers/video/fbdev/acornfb.h
@@ -7,7 +7,7 @@
* Frame buffer code for Acorn platforms
*/
#if defined(HAS_VIDC20)
-#include <asm/hardware/iomd.h>
+#include <mach/iomd.h>
#define VIDC_PALETTE_SIZE 256
#define VIDC_NAME "VIDC20"
#endif
--
2.43.0
^ permalink raw reply related
* [PATCH 0/2] backlight: add support for Silergy SY7758
From: Alexandre Hamamdjian via B4 Relay @ 2026-05-10 17:08 UTC (permalink / raw)
To: Philippe Simons, Lee Jones, Daniel Thompson, Jingoo Han,
Pavel Machek, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Helge Deller
Cc: dri-devel, linux-leds, devicetree, linux-kernel, linux-fbdev,
Alexandre Hamamdjian
The Silergy SY7758 is an I2C-controlled multi-channel LED backlight
driver used to drive the edge-lit LED strings of LCD panels. It is
present on the Ayaneo Pocket DS handheld, where it drives the panel
backlight, and is required before the panel can be lit.
This series adds the device tree binding for the new "silergy,sy7758"
compatible and the matching driver. The driver registers a backlight
class device with a 12-bit linear brightness range and programs the
chip's mode and current configuration registers on the first non-zero
brightness update.
The Ayaneo Pocket DS device tree, posted as a separate series, depends
on the binding introduced here to describe its panel backlight.
Signed-off-by: Alexandre Hamamdjian <azkali.limited@gmail.com>
---
Alexandre Hamamdjian (2):
dt-bindings: leds: backlight: add Silergy SY7758
backlight: sy7758: add Silergy SY7758 backlight driver
.../bindings/leds/backlight/silergy,sy7758.yaml | 47 ++++++
MAINTAINERS | 7 +
drivers/video/backlight/Kconfig | 14 ++
drivers/video/backlight/Makefile | 1 +
drivers/video/backlight/sy7758.c | 169 +++++++++++++++++++++
5 files changed, 238 insertions(+)
---
base-commit: e98d21c170b01ddef366f023bbfcf6b31509fa83
change-id: 20260510-sy7758-e46d85fd0876
Best regards,
--
Alexandre Hamamdjian <azkali.limited@gmail.com>
^ permalink raw reply
* [PATCH 2/2] backlight: sy7758: add Silergy SY7758 backlight driver
From: Alexandre Hamamdjian via B4 Relay @ 2026-05-10 17:08 UTC (permalink / raw)
To: Philippe Simons, Lee Jones, Daniel Thompson, Jingoo Han,
Pavel Machek, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Helge Deller
Cc: dri-devel, linux-leds, devicetree, linux-kernel, linux-fbdev,
Alexandre Hamamdjian
In-Reply-To: <20260511-sy7758-v1-0-999a33081304@gmail.com>
From: Alexandre Hamamdjian <azkali.limited@gmail.com>
Add a driver for the Silergy SY7758 I2C-controlled multi-channel LED
backlight controller. The chip drives the edge-lit LED strings of LCD
panels in handheld and embedded devices, and is for example present on
the Ayaneo Pocket DS handheld where it drives the panel backlight.
The driver registers a backlight class device with a 12-bit linear
brightness range. On the first non-zero update, the chip's mode and
current configuration registers are programmed; subsequent brightness
updates only rewrite the two brightness registers. A mutex serialises
concurrent updates against the deferred init path.
Co-developed-by: Philippe Simons <simons.philippe@gmail.com>
Signed-off-by: Philippe Simons <simons.philippe@gmail.com>
Signed-off-by: Alexandre Hamamdjian <azkali.limited@gmail.com>
---
drivers/video/backlight/Kconfig | 14 ++++
drivers/video/backlight/Makefile | 1 +
drivers/video/backlight/sy7758.c | 169 +++++++++++++++++++++++++++++++++++++++
3 files changed, 184 insertions(+)
diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig
index a7a3fbaf7c29..c529d2861525 100644
--- a/drivers/video/backlight/Kconfig
+++ b/drivers/video/backlight/Kconfig
@@ -461,6 +461,20 @@ config BACKLIGHT_SKY81452
To compile this driver as a module, choose M here: the module will
be called sky81452-backlight
+config BACKLIGHT_SY7758
+ tristate "Backlight Driver for Silergy SY7758"
+ depends on I2C
+ select REGMAP_I2C
+ help
+ This enables support for the Silergy SY7758 I2C-controlled
+ multi-channel LED backlight driver, commonly used to drive the
+ edge-lit LED strings of LCD panels in handheld and embedded
+ devices. The driver exposes a 12-bit linear brightness control
+ through the standard backlight class.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sy7758.
+
config BACKLIGHT_TPS65217
tristate "TPS65217 Backlight"
depends on MFD_TPS65217
diff --git a/drivers/video/backlight/Makefile b/drivers/video/backlight/Makefile
index 794820a98ed4..00d3e379b297 100644
--- a/drivers/video/backlight/Makefile
+++ b/drivers/video/backlight/Makefile
@@ -57,6 +57,7 @@ obj-$(CONFIG_BACKLIGHT_QCOM_WLED) += qcom-wled.o
obj-$(CONFIG_BACKLIGHT_RT4831) += rt4831-backlight.o
obj-$(CONFIG_BACKLIGHT_SAHARA) += kb3886_bl.o
obj-$(CONFIG_BACKLIGHT_SKY81452) += sky81452-backlight.o
+obj-$(CONFIG_BACKLIGHT_SY7758) += sy7758.o
obj-$(CONFIG_BACKLIGHT_TPS65217) += tps65217_bl.o
obj-$(CONFIG_BACKLIGHT_WM831X) += wm831x_bl.o
obj-$(CONFIG_BACKLIGHT_ARCXCNN) += arcxcnn_bl.o
diff --git a/drivers/video/backlight/sy7758.c b/drivers/video/backlight/sy7758.c
new file mode 100644
index 000000000000..6a318bd62030
--- /dev/null
+++ b/drivers/video/backlight/sy7758.c
@@ -0,0 +1,169 @@
+// SPDX-License-Identifier: GPL-2.0-only
+/*
+ * Backlight driver for the Silergy sy7758
+ *
+ * Copyright (C) 2025 Kancy Joe <kancy2333@outlook.com>
+ */
+
+#include <linux/backlight.h>
+#include <linux/err.h>
+#include <linux/gpio/consumer.h>
+#include <linux/i2c.h>
+#include <linux/module.h>
+#include <linux/of.h>
+#include <linux/regmap.h>
+
+#define DEFAULT_BRIGHTNESS 1500
+#define MAX_BRIGHTNESS 4080
+#define REG_MAX 0xa9
+
+#define BL_BRT_L 0x10
+#define BL_BRT_H 0x11
+
+static DEFINE_MUTEX(sy7758_update_backlight_mutex);
+
+struct sy7758 {
+ struct i2c_client *client;
+ struct regmap *regmap;
+ bool led_on;
+};
+
+static void sy7758_init(struct sy7758 *sydev);
+
+static const struct regmap_config sy7758_regmap_config = {
+ .reg_bits = 8,
+ .val_bits = 8,
+ .max_register = REG_MAX,
+};
+
+static int sy7758_write(struct sy7758 *sydev, unsigned int reg,
+ unsigned int val)
+{
+ return regmap_write(sydev->regmap, reg, val);
+}
+
+static int sy7758_backlight_update_status(struct backlight_device *backlight_dev)
+{
+ struct sy7758 *sydev = bl_get_data(backlight_dev);
+ unsigned int brightness = backlight_get_brightness(backlight_dev);
+
+ mutex_lock(&sy7758_update_backlight_mutex);
+
+ if (!sydev->led_on && brightness > 0) {
+ sy7758_init(sydev);
+ sydev->led_on = true;
+ } else if (brightness == 0) {
+ sydev->led_on = false;
+ }
+
+ sy7758_write(sydev, BL_BRT_L, brightness & 0xf0);
+
+ sy7758_write(sydev, BL_BRT_H, (brightness >> 8) & 0xf);
+
+ mutex_unlock(&sy7758_update_backlight_mutex);
+ return 0;
+}
+
+static const struct backlight_ops sy7758_backlight_ops = {
+ .options = BL_CORE_SUSPENDRESUME,
+ .update_status = sy7758_backlight_update_status,
+};
+
+static void sy7758_init(struct sy7758 *sydev)
+{
+ sy7758_write(sydev, 0x01, 0x85);
+ sy7758_write(sydev, 0x10, 0x00);
+ sy7758_write(sydev, 0x11, 0x00);
+ sy7758_write(sydev, 0xa5, 0x64);
+ sy7758_write(sydev, 0xa0, 0x55);
+ sy7758_write(sydev, 0xa1, 0x9a);
+ sy7758_write(sydev, 0xa9, 0x80);
+ sy7758_write(sydev, 0xa2, 0x28);
+
+ usleep_range(10000, 11000);
+
+ sy7758_write(sydev, 0x10, 0x40);
+ sy7758_write(sydev, 0x11, 0x01);
+ // Max brightness
+ // 0x10: 0xf0 Low
+ // 0x11: 0x0f High
+
+ // Min brightness
+ // 0x10: 0x10 Low
+ // 0x11: 0x00 High
+ sydev->led_on = true;
+}
+
+static int sy7758_probe(struct i2c_client *client)
+{
+ struct backlight_device *backlight_dev;
+ struct backlight_properties props;
+ struct sy7758 *sydev;
+
+ sydev = devm_kzalloc(&client->dev, sizeof(*sydev), GFP_KERNEL);
+ if (!sydev)
+ return -ENOMEM;
+
+ sydev->client = client;
+ sydev->regmap = devm_regmap_init_i2c(client, &sy7758_regmap_config);
+ if (IS_ERR(sydev->regmap))
+ return dev_err_probe(&client->dev, PTR_ERR(sydev->regmap),
+ "failed to init regmap\n");
+
+ memset(&props, 0, sizeof(props));
+ props.type = BACKLIGHT_RAW;
+ props.max_brightness = MAX_BRIGHTNESS;
+ props.brightness = DEFAULT_BRIGHTNESS;
+ props.scale = BACKLIGHT_SCALE_LINEAR;
+
+ backlight_dev = devm_backlight_device_register(&client->dev, "sy7758-backlight",
+ &client->dev, sydev, &sy7758_backlight_ops, &props);
+ if (IS_ERR(backlight_dev))
+ return dev_err_probe(&client->dev, PTR_ERR(backlight_dev),
+ "failed to register backlight device\n");
+
+ sy7758_init(sydev);
+
+ i2c_set_clientdata(client, backlight_dev);
+ backlight_update_status(backlight_dev);
+
+ return 0;
+}
+
+static void sy7758_remove(struct i2c_client *client)
+{
+ struct backlight_device *backlight_dev = i2c_get_clientdata(client);
+
+ backlight_dev->props.brightness = 0;
+ backlight_update_status(backlight_dev);
+}
+
+static const struct i2c_device_id sy7758_ids[] = {
+ { "sy7758" },
+ {}
+};
+MODULE_DEVICE_TABLE(i2c, sy7758_ids);
+
+static const struct of_device_id sy7758_match_table[] = {
+ {
+ .compatible = "silergy,sy7758",
+ },
+ {},
+};
+MODULE_DEVICE_TABLE(of, sy7758_match_table);
+
+static struct i2c_driver sy7758_driver = {
+ .driver = {
+ .name = "sy7758",
+ .of_match_table = sy7758_match_table,
+ },
+ .probe = sy7758_probe,
+ .remove = sy7758_remove,
+ .id_table = sy7758_ids,
+};
+
+module_i2c_driver(sy7758_driver);
+
+MODULE_DESCRIPTION("Silergy sy7758 Backlight Driver");
+MODULE_AUTHOR("Kancy Joe <kancy2333@outlook.com>");
+MODULE_LICENSE("GPL");
--
2.54.0
^ permalink raw reply related
* [PATCH 1/2] dt-bindings: leds: backlight: add Silergy SY7758
From: Alexandre Hamamdjian via B4 Relay @ 2026-05-10 17:08 UTC (permalink / raw)
To: Philippe Simons, Lee Jones, Daniel Thompson, Jingoo Han,
Pavel Machek, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Helge Deller
Cc: dri-devel, linux-leds, devicetree, linux-kernel, linux-fbdev,
Alexandre Hamamdjian
In-Reply-To: <20260511-sy7758-v1-0-999a33081304@gmail.com>
From: Alexandre Hamamdjian <azkali.limited@gmail.com>
The Silergy SY7758 is an I2C-controlled multi-channel LED backlight
driver typically used to drive the edge-lit LED strings of LCD panels
in handheld and embedded devices. Brightness is programmed as a 12-bit
linear value through two 8-bit registers.
Document the binding for the new compatible "silergy,sy7758" so it can
be referenced by board device trees and the matching driver, and add a
MAINTAINERS entry covering both the binding and the upcoming driver.
Co-developed-by: Philippe Simons <simons.philippe@gmail.com>
Signed-off-by: Philippe Simons <simons.philippe@gmail.com>
Signed-off-by: Alexandre Hamamdjian <azkali.limited@gmail.com>
---
.../bindings/leds/backlight/silergy,sy7758.yaml | 47 ++++++++++++++++++++++
MAINTAINERS | 7 ++++
2 files changed, 54 insertions(+)
diff --git a/Documentation/devicetree/bindings/leds/backlight/silergy,sy7758.yaml b/Documentation/devicetree/bindings/leds/backlight/silergy,sy7758.yaml
new file mode 100644
index 000000000000..408029e19e2e
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/backlight/silergy,sy7758.yaml
@@ -0,0 +1,47 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/leds/backlight/silergy,sy7758.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Silergy SY7758 I2C LED backlight controller
+
+maintainers:
+ - Alexandre Hamamdjian <azkali.limited@gmail.com>
+ - Philippe Simons <simons.philippe@gmail.com>
+
+description:
+ The Silergy SY7758 is an I2C-controlled multi-channel LED backlight
+ driver typically used to drive the edge-lit LED strings of LCD panels
+ in handheld and embedded devices. Brightness is programmed as a 12-bit
+ linear value through two 8-bit registers.
+
+allOf:
+ - $ref: common.yaml#
+
+properties:
+ compatible:
+ const: silergy,sy7758
+
+ reg:
+ maxItems: 1
+
+required:
+ - compatible
+ - reg
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ backlight@36 {
+ compatible = "silergy,sy7758";
+ reg = <0x36>;
+ max-brightness = <4080>;
+ default-brightness = <1500>;
+ };
+ };
diff --git a/MAINTAINERS b/MAINTAINERS
index f877e5aaf2c7..9c132394ca41 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -24561,6 +24561,13 @@ S: Maintained
F: drivers/input/touchscreen/silead.c
F: drivers/platform/x86/touchscreen_dmi.c
+SILERGY SY7758 BACKLIGHT DRIVER
+M: Alexandre Hamamdjian <azkali.limited@gmail.com>
+M: Philippe Simons <simons.philippe@gmail.com>
+S: Maintained
+F: Documentation/devicetree/bindings/leds/backlight/silergy,sy7758.yaml
+F: drivers/video/backlight/sy7758.c
+
SILICON LABS WIRELESS DRIVERS (for WFxxx series)
M: Jérôme Pouiller <jerome.pouiller@silabs.com>
L: linux-wireless@vger.kernel.org
--
2.54.0
^ permalink raw reply related
* Re: [PATCH] staging: sm750fb: Add const to g_fbmode array
From: Greg Kroah-Hartman @ 2026-05-11 7:57 UTC (permalink / raw)
To: Alone; +Cc: Sudip Mukherjee, Teddy Wang, linux-fbdev, linux-staging,
linux-kernel
In-Reply-To: <20260509164057.71722-1-yogeshdangal66@gmail.com>
On Sat, May 09, 2026 at 10:25:57PM +0545, Alone wrote:
> From: Chhabilal Dangal <yogeshdangal66@gmail.com>
>
> Add const qualifier to g_fbmode array since the array
> itself is not modified after initialization.
>
> Signed-off-by: Chhabilal Dangal <yogeshdangal66@gmail.com>
> ---
> drivers/staging/sm750fb/sm750.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> index 9f3e3d37e..19c3da654 100644
> --- a/drivers/staging/sm750fb/sm750.c
> +++ b/drivers/staging/sm750fb/sm750.c
> @@ -33,7 +33,7 @@
> static int g_hwcursor = 1;
> static int g_noaccel;
> static int g_nomtrr;
> -static const char *g_fbmode[] = {NULL, NULL};
> +static const char * const g_fbmode[] = {NULL, NULL};
> static const char *g_def_fbmode = "1024x768-32@60";
> static char *g_settings;
> static int g_dualview;
> --
> 2.54.0
>
>
Please always test-build your patches :(
^ permalink raw reply
* Re: [PATCH] staging: sm750fb: Add const to g_fbmode array
From: Greg Kroah-Hartman @ 2026-05-11 10:23 UTC (permalink / raw)
To: Alone; +Cc: Sudip Mukherjee, Teddy Wang, linux-fbdev, linux-staging,
linux-kernel
In-Reply-To: <CAF9nfaDEys+8bcnFRVWWoAvyrvPgXmENbASABG+4dBjMinaP5A@mail.gmail.com>
On Mon, May 11, 2026 at 04:04:40PM +0545, Alone wrote:
> Thanks for the feedback. I verified the patch with:
>
> make M=drivers/staging/sm750fb
>
> and it builds successfully. I’ll make sure to compile-test patches before
> submission next time.
I don't think you actually built the file you modified. Be sure the
correct config option is also enabled. Try it yourself and see!
Also, please don't top-post or send html email, the mailing lists reject
that.
thanks,
greg k-h
^ permalink raw reply
* Re: [PATCH] staging: sm750fb: Add const to g_fbmode array
From: Chhabilal Dangal @ 2026-05-11 10:52 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: Sudip Mukherjee, Teddy Wang, linux-fbdev, linux-staging,
linux-kernel
Thanks for catching that! I've now properly configured the kernel:
CONFIG_FB_SM750=m
CONFIG_STAGING=y
CONFIG_FB=y
Ran: make oldconfig
Verified configuration with: cat .config | grep CONFIG_FB_SM750
The patch should compile with these settings enabled. The changes are
minimal (adding const to g_fbmode array) and don't require additional
setup beyond proper kernel configuration.
Thanks for the guidance!
Chhabilal Dangal
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox