lkml.org 
[lkml]   [2009]   [Jul]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: PM/hibernate swapfile regression
On Tue, Jul 21, 2009 at 11:50:29AM +0100, Alan Jenkins wrote:
> +struct block_device *bdcopy(struct block_device *bdev)
> +{
> + atomic_inc(&bdev->bd_inode->i_count);
> + return bdev;
> +}
> +
> +EXPORT_SYMBOL(bdcopy);

The function name doesn't make any sense. You don't copy anything
here, but you grab a reference to it. A better name would be bdgrab,
mirroing the names of functions like igrab. A kerneldoc comment
documenting it would also be very helpful.

Why do you export it? The swapfile code is not actually modular.



\
 
 \ /
  Last update: 2009-07-21 23:57    [W:0.104 / U:0.364 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site