All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
To: Kees Cook <keescook@chromium.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	David Lechner <david@lechnology.com>,
	Daniel Vetter <daniel.vetter@ffwll.ch>,
	Sean Paul <seanpaul@chromium.org>,
	Jean Delvare <jdelvare@suse.de>,
	Hans de Goede <hdegoede@redhat.com>,
	"Gustavo A. R. Silva" <gustavo@embeddedor.com>,
	linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org,
	linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] video: fbdev: Convert timers to use timer_setup()
Date: Thu, 09 Nov 2017 17:08:26 +0000	[thread overview]
Message-ID: <15752127.NCT7iFVURk@amdc3058> (raw)
In-Reply-To: <20171024152026.GA104655@beast>

On Tuesday, October 24, 2017 08:20:26 AM Kees Cook wrote:

> diff --git a/drivers/video/fbdev/pxa3xx-gcu.c b/drivers/video/fbdev/pxa3xx-gcu.c
> index 933619da1a94..e88447eac32c 100644
> --- a/drivers/video/fbdev/pxa3xx-gcu.c
> +++ b/drivers/video/fbdev/pxa3xx-gcu.c
> @@ -513,16 +513,10 @@ pxa3xx_gcu_mmap(struct file *file, struct vm_area_struct *vma)
>  #ifdef PXA3XX_GCU_DEBUG_TIMER
>  static struct timer_list pxa3xx_gcu_debug_timer;
>  
> -static void pxa3xx_gcu_debug_timedout(unsigned long ptr)
> +static void pxa3xx_gcu_debug_timedout(struct timer_list *unused)
>  {
> -	struct pxa3xx_gcu_priv *priv = (struct pxa3xx_gcu_priv *) ptr;
> -
>  	QERROR("Timer DUMP");

QERROR() macro is using priv so this code now fails to build.

[ Please compile these timer changes with PXA3XX_GCU_DEBUG and
  PXA3XX_GCU_DEBUG_TIMER defined. ]

Also please port your changes over fbdvev-for-next tree as
currently this patch doesn't apply (fbdev tree contains
"video: fbdev: pxa3xx_gcu: Use setup_timer and mod_timer"
cleanup).

> -	/* init the timer structure */
> -	init_timer(&pxa3xx_gcu_debug_timer);
> -	pxa3xx_gcu_debug_timer.function = pxa3xx_gcu_debug_timedout;
> -	pxa3xx_gcu_debug_timer.data = ptr;
>  	pxa3xx_gcu_debug_timer.expires = jiffies + 5*HZ; /* one second */
>  
>  	add_timer(&pxa3xx_gcu_debug_timer);
> @@ -530,7 +524,9 @@ static void pxa3xx_gcu_debug_timedout(unsigned long ptr)
>  
>  static void pxa3xx_gcu_init_debug_timer(void)
>  {
> -	pxa3xx_gcu_debug_timedout((unsigned long) &pxa3xx_gcu_debug_timer);
> +	/* init the timer structure */
> +	timer_setup(&pxa3xx_gcu_debug_timer, pxa3xx_gcu_debug_timedout, 0);
> +	pxa3xx_gcu_debug_timedout(NULL);
>  }
>  #else
>  static inline void pxa3xx_gcu_init_debug_timer(void) {}

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


WARNING: multiple messages have this Message-ID (diff)
From: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
To: Kees Cook <keescook@chromium.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	David Lechner <david@lechnology.com>,
	Daniel Vetter <daniel.vetter@ffwll.ch>,
	Sean Paul <seanpaul@chromium.org>,
	Jean Delvare <jdelvare@suse.de>,
	Hans de Goede <hdegoede@redhat.com>,
	"Gustavo A. R. Silva" <gustavo@embeddedor.com>,
	linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org,
	linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] video: fbdev: Convert timers to use timer_setup()
Date: Thu, 09 Nov 2017 18:08:26 +0100	[thread overview]
Message-ID: <15752127.NCT7iFVURk@amdc3058> (raw)
In-Reply-To: <20171024152026.GA104655@beast>

On Tuesday, October 24, 2017 08:20:26 AM Kees Cook wrote:

> diff --git a/drivers/video/fbdev/pxa3xx-gcu.c b/drivers/video/fbdev/pxa3xx-gcu.c
> index 933619da1a94..e88447eac32c 100644
> --- a/drivers/video/fbdev/pxa3xx-gcu.c
> +++ b/drivers/video/fbdev/pxa3xx-gcu.c
> @@ -513,16 +513,10 @@ pxa3xx_gcu_mmap(struct file *file, struct vm_area_struct *vma)
>  #ifdef PXA3XX_GCU_DEBUG_TIMER
>  static struct timer_list pxa3xx_gcu_debug_timer;
>  
> -static void pxa3xx_gcu_debug_timedout(unsigned long ptr)
> +static void pxa3xx_gcu_debug_timedout(struct timer_list *unused)
>  {
> -	struct pxa3xx_gcu_priv *priv = (struct pxa3xx_gcu_priv *) ptr;
> -
>  	QERROR("Timer DUMP");

QERROR() macro is using priv so this code now fails to build.

[ Please compile these timer changes with PXA3XX_GCU_DEBUG and
  PXA3XX_GCU_DEBUG_TIMER defined. ]

Also please port your changes over fbdvev-for-next tree as
currently this patch doesn't apply (fbdev tree contains
"video: fbdev: pxa3xx_gcu: Use setup_timer and mod_timer"
cleanup).

> -	/* init the timer structure */
> -	init_timer(&pxa3xx_gcu_debug_timer);
> -	pxa3xx_gcu_debug_timer.function = pxa3xx_gcu_debug_timedout;
> -	pxa3xx_gcu_debug_timer.data = ptr;
>  	pxa3xx_gcu_debug_timer.expires = jiffies + 5*HZ; /* one second */
>  
>  	add_timer(&pxa3xx_gcu_debug_timer);
> @@ -530,7 +524,9 @@ static void pxa3xx_gcu_debug_timedout(unsigned long ptr)
>  
>  static void pxa3xx_gcu_init_debug_timer(void)
>  {
> -	pxa3xx_gcu_debug_timedout((unsigned long) &pxa3xx_gcu_debug_timer);
> +	/* init the timer structure */
> +	timer_setup(&pxa3xx_gcu_debug_timer, pxa3xx_gcu_debug_timedout, 0);
> +	pxa3xx_gcu_debug_timedout(NULL);
>  }
>  #else
>  static inline void pxa3xx_gcu_init_debug_timer(void) {}

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

  reply	other threads:[~2017-11-09 17:08 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20171024152032epcas3p4976e268e33d58750b7c09380e857bba0@epcas3p4.samsung.com>
2017-10-24 15:20 ` [PATCH] video: fbdev: Convert timers to use timer_setup() Kees Cook
2017-10-24 15:20   ` Kees Cook
2017-11-09 17:08   ` Bartlomiej Zolnierkiewicz [this message]
2017-11-09 17:08     ` Bartlomiej Zolnierkiewicz
2017-11-09 18:40     ` Kees Cook
2017-11-09 18:40       ` Kees Cook
2017-11-10 15:33       ` Bartlomiej Zolnierkiewicz
2017-11-10 15:33         ` Bartlomiej Zolnierkiewicz
2017-11-10 15:33         ` Bartlomiej Zolnierkiewicz
2017-11-14  1:45   ` Guenter Roeck
2017-11-14  1:45     ` Guenter Roeck
2017-11-14  3:18     ` Kees Cook
2017-11-14  3:18       ` Kees Cook

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=15752127.NCT7iFVURk@amdc3058 \
    --to=b.zolnierkie@samsung.com \
    --cc=benh@kernel.crashing.org \
    --cc=daniel.vetter@ffwll.ch \
    --cc=david@lechnology.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gustavo@embeddedor.com \
    --cc=hdegoede@redhat.com \
    --cc=jdelvare@suse.de \
    --cc=keescook@chromium.org \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=seanpaul@chromium.org \
    --cc=tomi.valkeinen@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.