Skip to contentSkip to conversation

typo in debugfs code comments?

DISCUSSION Bao Zhao 2 participants 4 messages Dec 10, 2005

lore
Share & tools
lore

Bao Zhao

author
#0 lore raw

I think that the comments of debugfs_create_u16 and
debugfs_create_u32
have the copy and paste error.

below is original comments.
/**
* debugfs_create_u16 - create a file in the debugfs
filesystem that is used to read and write a unsigned 8 bit value.
*

/**
* debugfs_create_u32 - create a file in the debugfs
filesystem that is used to read and write a unsigned 8 bit value.
*

It should be "a unsigned 16 bit value" and "a unsigned 32 bit value"

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

#1 lore raw
Quoted 11 lines · Bao Zhao

I think that the comments of debugfs_create_u16 and
debugfs_create_u32
have the copy and paste error.

below is original comments.
/**
* debugfs_create_u16 - create a file in the debugfs
filesystem that is used to read and write a unsigned 8 bit value.
*

Quoted 8 lines

/**
* debugfs_create_u32 - create a file in the debugfs
filesystem that is used to read and write a unsigned 8 bit value.
*

It should be "a unsigned 16 bit value" and "a unsigned 32 bit value"

Heh, cut and paste comments :)

Care to send me a patch, as per Documentation/SubmittingPatches to fix this up?

thanks,

greg k-h

author
#2 lore raw
Quoted 30 lines · --- Greg KH
Quoted 1 line · Bao Zhao

I think that the comments of debugfs_create_u16

and

Quoted 6 lines

debugfs_create_u32
have the copy and paste error.

below is original comments.
/**
* debugfs_create_u16 - create a file in the

debugfs

Quoted 1 line

filesystem that is used to read and write a

unsigned 8

Quoted 5 lines

bit value.
*

/**
* debugfs_create_u32 - create a file in the

debugfs

Quoted 1 line

filesystem that is used to read and write a

unsigned 8

Quoted 4 lines

bit value.
*

It should be "a unsigned 16 bit value" and "a

unsigned

Quoted 1 line

32 bit value"

Heh, cut and paste comments :)

Quoted 8 lines

Care to send me a patch, as per
Documentation/SubmittingPatches to fix
this up?

thanks,

greg k-h

This patch fixes cut and paste error in debugfs.

---

--- linux-2.6.14.3/fs/debugfs/file.c.orig 2005-12-03
17:39:41.000000000 -0500
+++ linux-2.6.14.3/fs/debugfs/file.c 2005-12-03
17:41:15.000000000 -0500
@@ -98,7 +98,7 @@ static u64 debugfs_u16_get(void *data)
DEFINE_SIMPLE_ATTRIBUTE(fops_u16, debugfs_u16_get,
debugfs_u16_set, "%llu\n");

/**
- * debugfs_create_u16 - create a file in the debugfs filesystem that is used to read and write a unsigned 8 bit value.
+ * debugfs_create_u16 - create a file in the debugfs filesystem that is used to read and write a unsigned 16 bit value.
*
* @name: a pointer to a string containing the name
of the file to create.
* @mode: the permission that the file should have
@@ -140,7 +140,7 @@ static u64 debugfs_u32_get(void *data)
DEFINE_SIMPLE_ATTRIBUTE(fops_u32, debugfs_u32_get,
debugfs_u32_set, "%llu\n");

/**
- * debugfs_create_u32 - create a file in the debugfs filesystem that is used to read and write a unsigned 8 bit value.
+ * debugfs_create_u32 - create a file in the debugfs filesystem that is used to read and write a unsigned 32 bit value.
*
* @name: a pointer to a string containing the name
of the file to create.
* @mode: the permission that the file should have

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

#3 lore raw

Review static u64 debugfs_u16_get(void · line 100

Quoted 8 lines · Bao Zhao

--- linux-2.6.14.3/fs/debugfs/file.c.orig 2005-12-03
17:39:41.000000000 -0500
+++ linux-2.6.14.3/fs/debugfs/file.c 2005-12-03
17:41:15.000000000 -0500

(quoted diff) +0 -0
@@ -98,7 +98,7 @@ static u64 debugfs_u16_get(void
 *data)
 DEFINE_SIMPLE_ATTRIBUTE(fops_u16, debugfs_u16_get,
 debugfs_u16_set, "%llu\n");

Your patch is linewrapped and can't be applied. Care to try again?

thanks,

greg k-h