public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Louis Zhuang <louis.zhuang@linux.co.intel.com>
To: Patrick Mochel <mochel@osdl.org>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: concerns about sysfs_ops
Date: 13 Jan 2003 19:17:16 +0800	[thread overview]
Message-ID: <1042456636.10860.11.camel@hawk.sh.intel.com> (raw)

Dear Mochel,
	I found you removed off/count params in new sysfs_ops functions. That's
good change for show functions, but for store function, if you don't
give the len of data, the chained xxx_store function has to assume
or/and guess how long the data is. This might be a potential issue. So I
suggest you add 'size_t count' in store function of sysfs_ops.

include/linux/sysfs.h:  1.21 1.22 louis 03/01/13 18:39:41 (modified, 
needs delta)

@@ -18,7 +18,7 @@
 
 struct sysfs_ops {
 	ssize_t	(*show)(struct kobject *, struct attribute *,char *);
-	ssize_t	(*store)(struct kobject *,struct attribute *,const char *);
+	ssize_t	(*store)(struct kobject *,struct attribute *,const char *,
size_t count);
 };
 
 extern int


Yours truly,
Louis Zhuang
---------------
Fault Injection Test Harness Project
BK tree: http://fault-injection.bkbits.net/linux-2.5
Home Page: http://sf.net/projects/fault-injection


             reply	other threads:[~2003-01-13 11:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-13 11:17 Louis Zhuang [this message]
2003-01-13 15:08 ` concerns about sysfs_ops Patrick Mochel
2003-01-14  0:43   ` Louis Zhuang

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=1042456636.10860.11.camel@hawk.sh.intel.com \
    --to=louis.zhuang@linux.co.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mochel@osdl.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox