forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f70575805708cabdedea7498aaa3f710fde4d920
kernel/drivers/video/fbdev/p9100.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /* p9100.c: P9100 frame buffer driver
23 *
34 * Copyright (C) 2003, 2006 David S. Miller (davem@davemloft.net)
....@@ -36,7 +37,7 @@
3637 * Frame buffer operations
3738 */
3839
39
-static struct fb_ops p9100_ops = {
40
+static const struct fb_ops p9100_ops = {
4041 .owner = THIS_MODULE,
4142 .fb_setcolreg = p9100_setcolreg,
4243 .fb_blank = p9100_blank,
....@@ -239,7 +240,7 @@
239240
240241 static void p9100_init_fix(struct fb_info *info, int linebytes, struct device_node *dp)
241242 {
242
- strlcpy(info->fix.id, dp->name, sizeof(info->fix.id));
243
+ snprintf(info->fix.id, sizeof(info->fix.id), "%pOFn", dp);
243244
244245 info->fix.type = FB_TYPE_PACKED_PIXELS;
245246 info->fix.visual = FB_VISUAL_PSEUDOCOLOR;