* [PATCH] drm: Don't export internal module variables
@ 2014-05-29 10:50 Daniel Vetter
2014-05-29 13:42 ` Alex Deucher
0 siblings, 1 reply; 8+ messages in thread
From: Daniel Vetter @ 2014-05-29 10:50 UTC (permalink / raw)
To: DRI Development; +Cc: Daniel Vetter
Drivers really have no business touching these. Noticed because
exynose _did_ touch the vblank off delay, which could potentially
affect other drivers.
drm_debug is an exception since it's used in macros and inline
functions.
Cc: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
drivers/gpu/drm/drm_stub.c | 12 ++++--------
drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
3 files changed, 4 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
index 3727ac8bc310..3901b41c214b 100644
--- a/drivers/gpu/drm/drm_stub.c
+++ b/drivers/gpu/drm/drm_stub.c
@@ -42,18 +42,14 @@
unsigned int drm_debug = 0; /* 1 to enable debug output */
EXPORT_SYMBOL(drm_debug);
-unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
-EXPORT_SYMBOL(drm_rnodes);
+int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
/* 1 to allow user space to request universal planes (experimental) */
-unsigned int drm_universal_planes = 0;
-EXPORT_SYMBOL(drm_universal_planes);
+int drm_universal_planes = 0;
-unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
-EXPORT_SYMBOL(drm_vblank_offdelay);
+int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
-unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
-EXPORT_SYMBOL(drm_timestamp_precision);
+int drm_timestamp_precision = 20; /* Default to 20 usecs. */
/*
* Default to use monotonic timestamps for wait-for-vblank and page-flip
diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
index 2d27ba23a6a8..d7c50b0da510 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
@@ -38,8 +38,6 @@
#define DRIVER_MAJOR 1
#define DRIVER_MINOR 0
-#define VBLANK_OFF_DELAY 50000
-
/* platform device pointer for eynos drm device. */
static struct platform_device *exynos_drm_pdev;
@@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
/* setup possible_clones. */
exynos_drm_encoder_setup(dev);
- drm_vblank_offdelay = VBLANK_OFF_DELAY;
-
platform_set_drvdata(dev->platformdev, dev);
/* force connectors detection */
diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h
index ce3e6a30deaa..e28f792d628c 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_drv.h
+++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h
@@ -40,8 +40,6 @@ struct drm_device;
struct exynos_drm_overlay;
struct drm_connector;
-extern unsigned int drm_vblank_offdelay;
-
/* this enumerates display type. */
enum exynos_drm_output_type {
EXYNOS_DISPLAY_TYPE_NONE,
--
1.9.2
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] drm: Don't export internal module variables
2014-05-29 10:50 Daniel Vetter
@ 2014-05-29 13:42 ` Alex Deucher
0 siblings, 0 replies; 8+ messages in thread
From: Alex Deucher @ 2014-05-29 13:42 UTC (permalink / raw)
To: Daniel Vetter; +Cc: DRI Development
On Thu, May 29, 2014 at 6:50 AM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> Drivers really have no business touching these. Noticed because
> exynose _did_ touch the vblank off delay, which could potentially
> affect other drivers.
>
> drm_debug is an exception since it's used in macros and inline
> functions.
>
> Cc: Inki Dae <inki.dae@samsung.com>
> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Seems reasonable to me. Was the type change intentional?
Alex
> ---
> drivers/gpu/drm/drm_stub.c | 12 ++++--------
> drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
> drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
> 3 files changed, 4 insertions(+), 14 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
> index 3727ac8bc310..3901b41c214b 100644
> --- a/drivers/gpu/drm/drm_stub.c
> +++ b/drivers/gpu/drm/drm_stub.c
> @@ -42,18 +42,14 @@
> unsigned int drm_debug = 0; /* 1 to enable debug output */
> EXPORT_SYMBOL(drm_debug);
>
> -unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
> -EXPORT_SYMBOL(drm_rnodes);
> +int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
>
> /* 1 to allow user space to request universal planes (experimental) */
> -unsigned int drm_universal_planes = 0;
> -EXPORT_SYMBOL(drm_universal_planes);
> +int drm_universal_planes = 0;
>
> -unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
> -EXPORT_SYMBOL(drm_vblank_offdelay);
> +int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
>
> -unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
> -EXPORT_SYMBOL(drm_timestamp_precision);
> +int drm_timestamp_precision = 20; /* Default to 20 usecs. */
>
> /*
> * Default to use monotonic timestamps for wait-for-vblank and page-flip
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> index 2d27ba23a6a8..d7c50b0da510 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
> +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> @@ -38,8 +38,6 @@
> #define DRIVER_MAJOR 1
> #define DRIVER_MINOR 0
>
> -#define VBLANK_OFF_DELAY 50000
> -
> /* platform device pointer for eynos drm device. */
> static struct platform_device *exynos_drm_pdev;
>
> @@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
> /* setup possible_clones. */
> exynos_drm_encoder_setup(dev);
>
> - drm_vblank_offdelay = VBLANK_OFF_DELAY;
> -
> platform_set_drvdata(dev->platformdev, dev);
>
> /* force connectors detection */
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> index ce3e6a30deaa..e28f792d628c 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_drv.h
> +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> @@ -40,8 +40,6 @@ struct drm_device;
> struct exynos_drm_overlay;
> struct drm_connector;
>
> -extern unsigned int drm_vblank_offdelay;
> -
> /* this enumerates display type. */
> enum exynos_drm_output_type {
> EXYNOS_DISPLAY_TYPE_NONE,
> --
> 1.9.2
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH] drm: Don't export internal module variables
@ 2014-05-29 17:25 Daniel Vetter
2014-05-29 18:25 ` Alex Deucher
2014-06-01 12:04 ` David Herrmann
0 siblings, 2 replies; 8+ messages in thread
From: Daniel Vetter @ 2014-05-29 17:25 UTC (permalink / raw)
To: DRI Development; +Cc: Daniel Vetter
Drivers really have no business touching these. Noticed because
exynose _did_ touch the vblank off delay, which could potentially
affect other drivers.
drm_debug is an exception since it's used in macros and inline
functions.
v2: Drop bonghits changes. Note to self: Don't submit patches
before first coffee.
Cc: Inki Dae <inki.dae@samsung.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
drivers/gpu/drm/drm_stub.c | 4 ----
drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
3 files changed, 10 deletions(-)
diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
index 3727ac8bc310..998782a88520 100644
--- a/drivers/gpu/drm/drm_stub.c
+++ b/drivers/gpu/drm/drm_stub.c
@@ -43,17 +43,13 @@ unsigned int drm_debug = 0; /* 1 to enable debug output */
EXPORT_SYMBOL(drm_debug);
unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
-EXPORT_SYMBOL(drm_rnodes);
/* 1 to allow user space to request universal planes (experimental) */
unsigned int drm_universal_planes = 0;
-EXPORT_SYMBOL(drm_universal_planes);
unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
-EXPORT_SYMBOL(drm_vblank_offdelay);
unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
-EXPORT_SYMBOL(drm_timestamp_precision);
/*
* Default to use monotonic timestamps for wait-for-vblank and page-flip
diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
index 2d27ba23a6a8..d7c50b0da510 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
@@ -38,8 +38,6 @@
#define DRIVER_MAJOR 1
#define DRIVER_MINOR 0
-#define VBLANK_OFF_DELAY 50000
-
/* platform device pointer for eynos drm device. */
static struct platform_device *exynos_drm_pdev;
@@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
/* setup possible_clones. */
exynos_drm_encoder_setup(dev);
- drm_vblank_offdelay = VBLANK_OFF_DELAY;
-
platform_set_drvdata(dev->platformdev, dev);
/* force connectors detection */
diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h
index ce3e6a30deaa..e28f792d628c 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_drv.h
+++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h
@@ -40,8 +40,6 @@ struct drm_device;
struct exynos_drm_overlay;
struct drm_connector;
-extern unsigned int drm_vblank_offdelay;
-
/* this enumerates display type. */
enum exynos_drm_output_type {
EXYNOS_DISPLAY_TYPE_NONE,
--
1.9.2
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] drm: Don't export internal module variables
2014-05-29 17:25 [PATCH] drm: Don't export internal module variables Daniel Vetter
@ 2014-05-29 18:25 ` Alex Deucher
2014-06-01 12:04 ` David Herrmann
1 sibling, 0 replies; 8+ messages in thread
From: Alex Deucher @ 2014-05-29 18:25 UTC (permalink / raw)
To: Daniel Vetter; +Cc: DRI Development
On Thu, May 29, 2014 at 1:25 PM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> Drivers really have no business touching these. Noticed because
> exynose _did_ touch the vblank off delay, which could potentially
> affect other drivers.
>
> drm_debug is an exception since it's used in macros and inline
> functions.
>
> v2: Drop bonghits changes. Note to self: Don't submit patches
> before first coffee.
>
> Cc: Inki Dae <inki.dae@samsung.com>
> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
> ---
> drivers/gpu/drm/drm_stub.c | 4 ----
> drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
> drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
> 3 files changed, 10 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
> index 3727ac8bc310..998782a88520 100644
> --- a/drivers/gpu/drm/drm_stub.c
> +++ b/drivers/gpu/drm/drm_stub.c
> @@ -43,17 +43,13 @@ unsigned int drm_debug = 0; /* 1 to enable debug output */
> EXPORT_SYMBOL(drm_debug);
>
> unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
> -EXPORT_SYMBOL(drm_rnodes);
>
> /* 1 to allow user space to request universal planes (experimental) */
> unsigned int drm_universal_planes = 0;
> -EXPORT_SYMBOL(drm_universal_planes);
>
> unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
> -EXPORT_SYMBOL(drm_vblank_offdelay);
>
> unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
> -EXPORT_SYMBOL(drm_timestamp_precision);
>
> /*
> * Default to use monotonic timestamps for wait-for-vblank and page-flip
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> index 2d27ba23a6a8..d7c50b0da510 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
> +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> @@ -38,8 +38,6 @@
> #define DRIVER_MAJOR 1
> #define DRIVER_MINOR 0
>
> -#define VBLANK_OFF_DELAY 50000
> -
> /* platform device pointer for eynos drm device. */
> static struct platform_device *exynos_drm_pdev;
>
> @@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
> /* setup possible_clones. */
> exynos_drm_encoder_setup(dev);
>
> - drm_vblank_offdelay = VBLANK_OFF_DELAY;
> -
> platform_set_drvdata(dev->platformdev, dev);
>
> /* force connectors detection */
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> index ce3e6a30deaa..e28f792d628c 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_drv.h
> +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> @@ -40,8 +40,6 @@ struct drm_device;
> struct exynos_drm_overlay;
> struct drm_connector;
>
> -extern unsigned int drm_vblank_offdelay;
> -
> /* this enumerates display type. */
> enum exynos_drm_output_type {
> EXYNOS_DISPLAY_TYPE_NONE,
> --
> 1.9.2
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] drm: Don't export internal module variables
2014-05-29 17:25 [PATCH] drm: Don't export internal module variables Daniel Vetter
2014-05-29 18:25 ` Alex Deucher
@ 2014-06-01 12:04 ` David Herrmann
2014-06-02 8:01 ` Daniel Vetter
1 sibling, 1 reply; 8+ messages in thread
From: David Herrmann @ 2014-06-01 12:04 UTC (permalink / raw)
To: Daniel Vetter; +Cc: DRI Development
Hi
On Thu, May 29, 2014 at 7:25 PM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> Drivers really have no business touching these. Noticed because
> exynose _did_ touch the vblank off delay, which could potentially
> affect other drivers.
>
> drm_debug is an exception since it's used in macros and inline
> functions.
>
> v2: Drop bonghits changes. Note to self: Don't submit patches
> before first coffee.
>
> Cc: Inki Dae <inki.dae@samsung.com>
> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> ---
> drivers/gpu/drm/drm_stub.c | 4 ----
> drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
> drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
> 3 files changed, 10 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
> index 3727ac8bc310..998782a88520 100644
> --- a/drivers/gpu/drm/drm_stub.c
> +++ b/drivers/gpu/drm/drm_stub.c
> @@ -43,17 +43,13 @@ unsigned int drm_debug = 0; /* 1 to enable debug output */
> EXPORT_SYMBOL(drm_debug);
>
> unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
> -EXPORT_SYMBOL(drm_rnodes);
>
> /* 1 to allow user space to request universal planes (experimental) */
> unsigned int drm_universal_planes = 0;
> -EXPORT_SYMBOL(drm_universal_planes);
>
> unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
> -EXPORT_SYMBOL(drm_vblank_offdelay);
>
> unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
> -EXPORT_SYMBOL(drm_timestamp_precision);
>
> /*
> * Default to use monotonic timestamps for wait-for-vblank and page-flip
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> index 2d27ba23a6a8..d7c50b0da510 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
> +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> @@ -38,8 +38,6 @@
> #define DRIVER_MAJOR 1
> #define DRIVER_MINOR 0
>
> -#define VBLANK_OFF_DELAY 50000
> -
> /* platform device pointer for eynos drm device. */
> static struct platform_device *exynos_drm_pdev;
>
> @@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
> /* setup possible_clones. */
> exynos_drm_encoder_setup(dev);
>
> - drm_vblank_offdelay = VBLANK_OFF_DELAY;
You know that this is 5,000 by default and VBLANK_OFF_DELAY is 50,000?
Not sure whether that was a typo or was explicitly set this way. If
that change is intentional:
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Thanks
David
> -
> platform_set_drvdata(dev->platformdev, dev);
>
> /* force connectors detection */
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> index ce3e6a30deaa..e28f792d628c 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_drv.h
> +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> @@ -40,8 +40,6 @@ struct drm_device;
> struct exynos_drm_overlay;
> struct drm_connector;
>
> -extern unsigned int drm_vblank_offdelay;
> -
> /* this enumerates display type. */
> enum exynos_drm_output_type {
> EXYNOS_DISPLAY_TYPE_NONE,
> --
> 1.9.2
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] drm: Don't export internal module variables
2014-06-01 12:04 ` David Herrmann
@ 2014-06-02 8:01 ` Daniel Vetter
2014-06-02 10:08 ` David Herrmann
0 siblings, 1 reply; 8+ messages in thread
From: Daniel Vetter @ 2014-06-02 8:01 UTC (permalink / raw)
To: David Herrmann; +Cc: Daniel Vetter, DRI Development
On Sun, Jun 01, 2014 at 02:04:45PM +0200, David Herrmann wrote:
> Hi
>
> On Thu, May 29, 2014 at 7:25 PM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> > Drivers really have no business touching these. Noticed because
> > exynose _did_ touch the vblank off delay, which could potentially
> > affect other drivers.
> >
> > drm_debug is an exception since it's used in macros and inline
> > functions.
> >
> > v2: Drop bonghits changes. Note to self: Don't submit patches
> > before first coffee.
> >
> > Cc: Inki Dae <inki.dae@samsung.com>
> > Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> > ---
> > drivers/gpu/drm/drm_stub.c | 4 ----
> > drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
> > drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
> > 3 files changed, 10 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
> > index 3727ac8bc310..998782a88520 100644
> > --- a/drivers/gpu/drm/drm_stub.c
> > +++ b/drivers/gpu/drm/drm_stub.c
> > @@ -43,17 +43,13 @@ unsigned int drm_debug = 0; /* 1 to enable debug output */
> > EXPORT_SYMBOL(drm_debug);
> >
> > unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
> > -EXPORT_SYMBOL(drm_rnodes);
> >
> > /* 1 to allow user space to request universal planes (experimental) */
> > unsigned int drm_universal_planes = 0;
> > -EXPORT_SYMBOL(drm_universal_planes);
> >
> > unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
> > -EXPORT_SYMBOL(drm_vblank_offdelay);
> >
> > unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
> > -EXPORT_SYMBOL(drm_timestamp_precision);
> >
> > /*
> > * Default to use monotonic timestamps for wait-for-vblank and page-flip
> > diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> > index 2d27ba23a6a8..d7c50b0da510 100644
> > --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
> > +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> > @@ -38,8 +38,6 @@
> > #define DRIVER_MAJOR 1
> > #define DRIVER_MINOR 0
> >
> > -#define VBLANK_OFF_DELAY 50000
> > -
> > /* platform device pointer for eynos drm device. */
> > static struct platform_device *exynos_drm_pdev;
> >
> > @@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
> > /* setup possible_clones. */
> > exynos_drm_encoder_setup(dev);
> >
> > - drm_vblank_offdelay = VBLANK_OFF_DELAY;
>
> You know that this is 5,000 by default and VBLANK_OFF_DELAY is 50,000?
> Not sure whether that was a typo or was explicitly set this way. If
> that change is intentional:
Oops, didn't spot that, nice catch. git log says this was added to paper
over a race in get/put_vblank in exynos. Wtf, imo even more reason to nuke
this ... I've pimped the commit message a bit - still r-b?
-Daniel
> Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
>
> Thanks
> David
>
> > -
> > platform_set_drvdata(dev->platformdev, dev);
> >
> > /* force connectors detection */
> > diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> > index ce3e6a30deaa..e28f792d628c 100644
> > --- a/drivers/gpu/drm/exynos/exynos_drm_drv.h
> > +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h
> > @@ -40,8 +40,6 @@ struct drm_device;
> > struct exynos_drm_overlay;
> > struct drm_connector;
> >
> > -extern unsigned int drm_vblank_offdelay;
> > -
> > /* this enumerates display type. */
> > enum exynos_drm_output_type {
> > EXYNOS_DISPLAY_TYPE_NONE,
> > --
> > 1.9.2
> >
> > _______________________________________________
> > dri-devel mailing list
> > dri-devel@lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/dri-devel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] drm: Don't export internal module variables
2014-06-02 8:01 ` Daniel Vetter
@ 2014-06-02 10:08 ` David Herrmann
2014-06-02 15:07 ` Daniel Vetter
0 siblings, 1 reply; 8+ messages in thread
From: David Herrmann @ 2014-06-02 10:08 UTC (permalink / raw)
To: Daniel Vetter; +Cc: Daniel Vetter, DRI Development
Hi
On Mon, Jun 2, 2014 at 10:01 AM, Daniel Vetter <daniel@ffwll.ch> wrote:
> On Sun, Jun 01, 2014 at 02:04:45PM +0200, David Herrmann wrote:
>> Hi
>>
>> On Thu, May 29, 2014 at 7:25 PM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
>> > Drivers really have no business touching these. Noticed because
>> > exynose _did_ touch the vblank off delay, which could potentially
>> > affect other drivers.
>> >
>> > drm_debug is an exception since it's used in macros and inline
>> > functions.
>> >
>> > v2: Drop bonghits changes. Note to self: Don't submit patches
>> > before first coffee.
>> >
>> > Cc: Inki Dae <inki.dae@samsung.com>
>> > Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
>> > ---
>> > drivers/gpu/drm/drm_stub.c | 4 ----
>> > drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
>> > drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
>> > 3 files changed, 10 deletions(-)
>> >
>> > diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
>> > index 3727ac8bc310..998782a88520 100644
>> > --- a/drivers/gpu/drm/drm_stub.c
>> > +++ b/drivers/gpu/drm/drm_stub.c
>> > @@ -43,17 +43,13 @@ unsigned int drm_debug = 0; /* 1 to enable debug output */
>> > EXPORT_SYMBOL(drm_debug);
>> >
>> > unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
>> > -EXPORT_SYMBOL(drm_rnodes);
>> >
>> > /* 1 to allow user space to request universal planes (experimental) */
>> > unsigned int drm_universal_planes = 0;
>> > -EXPORT_SYMBOL(drm_universal_planes);
>> >
>> > unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
>> > -EXPORT_SYMBOL(drm_vblank_offdelay);
>> >
>> > unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
>> > -EXPORT_SYMBOL(drm_timestamp_precision);
>> >
>> > /*
>> > * Default to use monotonic timestamps for wait-for-vblank and page-flip
>> > diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
>> > index 2d27ba23a6a8..d7c50b0da510 100644
>> > --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
>> > +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
>> > @@ -38,8 +38,6 @@
>> > #define DRIVER_MAJOR 1
>> > #define DRIVER_MINOR 0
>> >
>> > -#define VBLANK_OFF_DELAY 50000
>> > -
>> > /* platform device pointer for eynos drm device. */
>> > static struct platform_device *exynos_drm_pdev;
>> >
>> > @@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
>> > /* setup possible_clones. */
>> > exynos_drm_encoder_setup(dev);
>> >
>> > - drm_vblank_offdelay = VBLANK_OFF_DELAY;
>>
>> You know that this is 5,000 by default and VBLANK_OFF_DELAY is 50,000?
>> Not sure whether that was a typo or was explicitly set this way. If
>> that change is intentional:
>
> Oops, didn't spot that, nice catch. git log says this was added to paper
> over a race in get/put_vblank in exynos. Wtf, imo even more reason to nuke
> this ... I've pimped the commit message a bit - still r-b?
You mean:
commit 52c68814cd7f3592292a02b890b5b8625e9069a7
Author: Inki Dae <inki.dae@samsung.com>
Date: Fri Dec 16 21:31:12 2011 +0900
drm/exynos: extend vblank off delay time.
Yeah, that one doesn't make any sense. So this is still:
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Thanks
David
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] drm: Don't export internal module variables
2014-06-02 10:08 ` David Herrmann
@ 2014-06-02 15:07 ` Daniel Vetter
0 siblings, 0 replies; 8+ messages in thread
From: Daniel Vetter @ 2014-06-02 15:07 UTC (permalink / raw)
To: David Herrmann; +Cc: Daniel Vetter, DRI Development
On Mon, Jun 02, 2014 at 12:08:39PM +0200, David Herrmann wrote:
> Hi
>
> On Mon, Jun 2, 2014 at 10:01 AM, Daniel Vetter <daniel@ffwll.ch> wrote:
> > On Sun, Jun 01, 2014 at 02:04:45PM +0200, David Herrmann wrote:
> >> Hi
> >>
> >> On Thu, May 29, 2014 at 7:25 PM, Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> >> > Drivers really have no business touching these. Noticed because
> >> > exynose _did_ touch the vblank off delay, which could potentially
> >> > affect other drivers.
> >> >
> >> > drm_debug is an exception since it's used in macros and inline
> >> > functions.
> >> >
> >> > v2: Drop bonghits changes. Note to self: Don't submit patches
> >> > before first coffee.
> >> >
> >> > Cc: Inki Dae <inki.dae@samsung.com>
> >> > Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> >> > ---
> >> > drivers/gpu/drm/drm_stub.c | 4 ----
> >> > drivers/gpu/drm/exynos/exynos_drm_drv.c | 4 ----
> >> > drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 --
> >> > 3 files changed, 10 deletions(-)
> >> >
> >> > diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c
> >> > index 3727ac8bc310..998782a88520 100644
> >> > --- a/drivers/gpu/drm/drm_stub.c
> >> > +++ b/drivers/gpu/drm/drm_stub.c
> >> > @@ -43,17 +43,13 @@ unsigned int drm_debug = 0; /* 1 to enable debug output */
> >> > EXPORT_SYMBOL(drm_debug);
> >> >
> >> > unsigned int drm_rnodes = 0; /* 1 to enable experimental render nodes API */
> >> > -EXPORT_SYMBOL(drm_rnodes);
> >> >
> >> > /* 1 to allow user space to request universal planes (experimental) */
> >> > unsigned int drm_universal_planes = 0;
> >> > -EXPORT_SYMBOL(drm_universal_planes);
> >> >
> >> > unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */
> >> > -EXPORT_SYMBOL(drm_vblank_offdelay);
> >> >
> >> > unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */
> >> > -EXPORT_SYMBOL(drm_timestamp_precision);
> >> >
> >> > /*
> >> > * Default to use monotonic timestamps for wait-for-vblank and page-flip
> >> > diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.c b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> >> > index 2d27ba23a6a8..d7c50b0da510 100644
> >> > --- a/drivers/gpu/drm/exynos/exynos_drm_drv.c
> >> > +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.c
> >> > @@ -38,8 +38,6 @@
> >> > #define DRIVER_MAJOR 1
> >> > #define DRIVER_MINOR 0
> >> >
> >> > -#define VBLANK_OFF_DELAY 50000
> >> > -
> >> > /* platform device pointer for eynos drm device. */
> >> > static struct platform_device *exynos_drm_pdev;
> >> >
> >> > @@ -109,8 +107,6 @@ static int exynos_drm_load(struct drm_device *dev, unsigned long flags)
> >> > /* setup possible_clones. */
> >> > exynos_drm_encoder_setup(dev);
> >> >
> >> > - drm_vblank_offdelay = VBLANK_OFF_DELAY;
> >>
> >> You know that this is 5,000 by default and VBLANK_OFF_DELAY is 50,000?
> >> Not sure whether that was a typo or was explicitly set this way. If
> >> that change is intentional:
> >
> > Oops, didn't spot that, nice catch. git log says this was added to paper
> > over a race in get/put_vblank in exynos. Wtf, imo even more reason to nuke
> > this ... I've pimped the commit message a bit - still r-b?
>
> You mean:
>
> commit 52c68814cd7f3592292a02b890b5b8625e9069a7
> Author: Inki Dae <inki.dae@samsung.com>
> Date: Fri Dec 16 21:31:12 2011 +0900
>
> drm/exynos: extend vblank off delay time.
>
> Yeah, that one doesn't make any sense. So this is still:
Yup.
> Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Thanks, Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2014-06-02 15:07 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-29 17:25 [PATCH] drm: Don't export internal module variables Daniel Vetter
2014-05-29 18:25 ` Alex Deucher
2014-06-01 12:04 ` David Herrmann
2014-06-02 8:01 ` Daniel Vetter
2014-06-02 10:08 ` David Herrmann
2014-06-02 15:07 ` Daniel Vetter
-- strict thread matches above, loose matches on Subject: below --
2014-05-29 10:50 Daniel Vetter
2014-05-29 13:42 ` Alex Deucher
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox