lkml.org 
[lkml]   [2008]   [Sep]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 3/5] watchdog: cleanup a bit omap_wdt.c
Date
On Friday 19 September 2008, Felipe Balbi wrote:
>  static int omap_wdt_open(struct inode *inode, struct file *file)
>  {
> -       struct omap_wdt_dev *wdev;
> -       void __iomem *base;
> -       wdev = platform_get_drvdata(omap_wdt_dev);
> -       base = wdev->base;
> +       struct omap_wdt_dev *wdev = platform_get_drvdata(omap_wdt_dev);
> +       void __iomem *base = wdev->base;
> +

Oh, I see where "omap_wdt_dev" (global) gets used. The normal
way to do stuff like that is using void* pointers placed in the
inode and file structures for exactly that purpose.


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2008-09-20 02:45    [W:0.128 / U:0.544 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site