Re: [PATCH] staging: sm750fb: constify g_fbmode array

From: dipesh chaudhary

Date: Mon Mar 09 2026 - 06:13:44 EST



Hi Greg,

You were absolutely right. I just set up my local build environment and ran `make drivers/staging/sm750fb/sm750.o`, and it immediately threw `error: assignment of read-only location`.

I fell into the classic checkpatch trap. I blindly applied the `const` suggestion without checking the surrounding code, failing to realize the driver dynamically writes to `g_fbmode` during runtime in `sm750fb_setup` and `lynxfb_set_fbinfo`.

Thank you for pushing me to test-build. I will drop this patch entirely, as the checkpatch warning is a false positive here. I have learned a valuable lesson about not trusting static analysis scripts over actually reading the C code and compiling it.

Best regards,
Dipesh Chaudhary