Skip to contentSkip to conversation

video: fbdev: Fix checkpatch warnings in goldfishfb.c

PATCH In review [email protected] 2 participants 8 messages Jun 8, 2018 – Jul 3, 2018 Framebuffer layer

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/3 video: fbdev: Fix checkpatch warnings in goldfishfb.c

From: Roman Kiryanov <[email protected]>

Address issues pointed by checkpatch.pl

---
Changes in v2:
- Updated the commit message to include "video: fbdev:" and added a description.

 drivers/video/fbdev/goldfishfb.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/video/fbdev/goldfishfb.c +3 -1
index 3b70044773b6..de29c4ff77e5 100644
@@ -124,6 +124,7 @@ static int goldfish_fb_check_var(struct fb_var_screeninfo *var,
 static int goldfish_fb_set_par(struct fb_info *info)
 {
 	struct goldfish_fb *fb = container_of(info, struct goldfish_fb, fb);
+
 	if (fb->rotation != fb->fb.var.rotate) {
 		info->fix.line_length = info->var.xres * 2;
 		fb->rotation = fb->fb.var.rotate;
@@ -148,13 +149,14 @@ static int goldfish_fb_pan_display(struct fb_var_screeninfo *var,
 	wait_event_timeout(fb->wait,
 			fb->base_update_count != base_update_count, HZ / 15);
 	if (fb->base_update_count == base_update_count)
-		pr_err("goldfish_fb_pan_display: timeout waiting for base update\n");
+		pr_err("%s: timeout waiting for base update\n", __func__);
 	return 0;
 }
 
 static int goldfish_fb_blank(int blank, struct fb_info *info)
 {
 	struct goldfish_fb *fb = container_of(info, struct goldfish_fb, fb);
+
 	switch (blank) {
 	case FB_BLANK_NORMAL:
 		writel(1, fb->reg_base + FB_SET_BLANK);
Signature · 6 lines
2.18.0.rc1.242.g61856ae69a-goog

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#1 lore raw

PATCH v2 2/3 video: fbdev: Enable ACPI-based enumeration for goldfishfb

From: Yu Ning <[email protected]>

Add an ACPI id to make goldfish framebuffer to support ACPI enumeration.

---
Changes in v2:
- Removed references to commits outside of kernel.org.
- Updated the commit description.

 drivers/video/fbdev/goldfishfb.c | 8 ++++++++
 1 file changed, 8 insertions(+)
drivers/video/fbdev/goldfishfb.c +8 -0
index de29c4ff77e5..01732858b60d 100644
@@ -26,6 +26,7 @@
 #include <linux/interrupt.h>
 #include <linux/ioport.h>
 #include <linux/platform_device.h>
+#include <linux/acpi.h>
 
 enum {
 	FB_GET_WIDTH        = 0x00,
@@ -312,12 +313,19 @@ static const struct of_device_id goldfish_fb_of_match[] = {
 };
 MODULE_DEVICE_TABLE(of, goldfish_fb_of_match);
 
+static const struct acpi_device_id goldfish_fb_acpi_match[] = {
+	{ "GFSH0004", 0 },
+	{ },
+};
+MODULE_DEVICE_TABLE(acpi, goldfish_fb_acpi_match);
+
 static struct platform_driver goldfish_fb_driver = {
 	.probe		= goldfish_fb_probe,
 	.remove		= goldfish_fb_remove,
 	.driver = {
 		.name = "goldfish_fb",
 		.of_match_table = goldfish_fb_of_match,
+		.acpi_match_table = ACPI_PTR(goldfish_fb_acpi_match),
 	}
 };
 
Signature · 6 lines
2.18.0.rc1.242.g61856ae69a-goog

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#2 lore raw

Re: [PATCH v2 2/3] video: fbdev: Enable ACPI-based enumeration for goldfishfb

Quoted 6 lines · On Friday, June 08, 2018 12:10:59 PM [email protected] wrote:

From: Yu Ning <[email protected]>

Add an ACPI id to make goldfish framebuffer to support ACPI enumeration.

Patch queued for 4.19, thanks.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#3 lore raw

PATCH v2 3/3 video: fbdev: Set pixclock = 0 in goldfishfb

In reply to [email protected]

From: Christoffer Dall <[email protected]>

User space Android code identifies pixclock == 0 as a sign for emulation and will set the frame rate to 60 fps when reading this value, which is the desired outcome.

---
Changes in v2:
- Updated the commit message to include "video: fbdev:".
- Dropped Change-Id.
- Signed-off the commit.

 drivers/video/fbdev/goldfishfb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/video/fbdev/goldfishfb.c +1 -1
index 01732858b60d..3a9e5f1b758e 100644
@@ -237,7 +237,7 @@ static int goldfish_fb_probe(struct platform_device *pdev)
 	fb->fb.var.activate	= FB_ACTIVATE_NOW;
 	fb->fb.var.height	= readl(fb->reg_base + FB_GET_PHYS_HEIGHT);
 	fb->fb.var.width	= readl(fb->reg_base + FB_GET_PHYS_WIDTH);
-	fb->fb.var.pixclock	= 10000;
+	fb->fb.var.pixclock	= 0;
 
 	fb->fb.var.red.offset = 11;
 	fb->fb.var.red.length = 5;
Signature · 6 lines
2.18.0.rc1.242.g61856ae69a-goog

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#4 lore raw

Re: [PATCH v2 3/3] video: fbdev: Set pixclock = 0 in goldfishfb

Quoted 9 lines · On Friday, June 08, 2018 12:11:00 PM [email protected] wrote:

From: Christoffer Dall <[email protected]>

User space Android code identifies pixclock == 0 as a sign for emulation and will set the frame rate to 60 fps when reading this value, which is the desired outcome.

Patch queued for 4.19, thanks.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#5 lore raw
In reply to [email protected]

Hi,

could you please confirm you received our patches? Thank you.

Regards,
Roman.

Quoted 42 lines · On Fri, Jun 8, 2018 at 12:11 PM <[email protected]> wrote:

From: Roman Kiryanov <[email protected]>

Address issues pointed by checkpatch.pl

---
Changes in v2:
- Updated the commit message to include "video: fbdev:" and added a description.

 drivers/video/fbdev/goldfishfb.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/video/fbdev/goldfishfb.c +3 -2
index 3b70044773b6..de29c4ff77e5 100644
@@ -124,6 +124,7 @@ static int goldfish_fb_check_var(struct fb_var_screeninfo *var,
 static int goldfish_fb_set_par(struct fb_info *info)
 {
        struct goldfish_fb *fb = container_of(info, struct goldfish_fb, fb);
+
        if (fb->rotation != fb->fb.var.rotate) {
                info->fix.line_length = info->var.xres * 2;
                fb->rotation = fb->fb.var.rotate;
@@ -148,13 +149,14 @@ static int goldfish_fb_pan_display(struct fb_var_screeninfo *var,
        wait_event_timeout(fb->wait,
                        fb->base_update_count != base_update_count, HZ / 15);
        if (fb->base_update_count == base_update_count)
-               pr_err("goldfish_fb_pan_display: timeout waiting for base update\n");
+               pr_err("%s: timeout waiting for base update\n", __func__);
        return 0;
 }
 
 static int goldfish_fb_blank(int blank, struct fb_info *info)
 {
        struct goldfish_fb *fb = container_of(info, struct goldfish_fb, fb);
+
        switch (blank) {
        case FB_BLANK_NORMAL:
                writel(1, fb->reg_base + FB_SET_BLANK);
--
Quoted 2 lines

2.18.0.rc1.242.g61856ae69a-goog

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#6 lore raw
Quoted 3 lines · Roman Kiryanov

Hi,

could you please confirm you received our patches? Thank you.

Hi,

Yes, they are in my inbox waiting for their turn
(I'll start queuing patches for v4.19 later this
week).

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

#7 lore raw
In reply to [email protected]
Quoted 5 lines · On Friday, June 08, 2018 12:10:58 PM [email protected] wrote:

From: Roman Kiryanov <[email protected]>

Address issues pointed by checkpatch.pl

Patch queued for 4.19, thanks.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel