All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wen Xiong <wendyx@us.ibm.com>
To: Greg KH <greg@kroah.com>
Cc: Wen Xiong <wendyx@us.ibm.com>, linux-kernel@vger.kernel.org
Subject: Re: [ patch 4/7] drivers/serial/jsm: new serial device driver
Date: Wed, 09 Mar 2005 12:18:21 -0500	[thread overview]
Message-ID: <422F2FDD.4050908@us.ltcfwd.linux.ibm.com> (raw)
In-Reply-To: <20050309163518.GC25079@kroah.com>

[-- Attachment #1: Type: text/plain, Size: 568 bytes --]

Greg KH wrote:

>On Wed, Mar 09, 2005 at 10:47:22AM -0500, Wen Xiong wrote:
>  
>
>>+static ssize_t jsm_driver_debug_show(struct device_driver *ddp, char *buf)
>>+{
>>+	return snprintf(buf, PAGE_SIZE, "0x%x\n", jsm_debug);
>>+}
>>+static DRIVER_ATTR(debug, S_IRUSR, jsm_driver_debug_show, NULL);
>>    
>>
>
>Should just be a module paramater, right?  So you can drop this too...
>
>This file is getting quite small now :)
>
>thanks,
>
>greg k-h
>
>  
>
If I removed two module paramaters, only two files left: version and state.
 Removed all of them?

Thanks,
wendy


[-- Attachment #2: patch4.jasmine --]
[-- Type: text/plain, Size: 2332 bytes --]

diff -Nuar linux-2.6.11.org/drivers/serial/jsm/jsm_sysfs.c linux-2.6.11.new/drivers/serial/jsm/jsm_sysfs.c
--- linux-2.6.11.org/drivers/serial/jsm/jsm_sysfs.c	1969-12-31 18:00:00.000000000 -0600
+++ linux-2.6.11.new/drivers/serial/jsm/jsm_sysfs.c	2005-03-09 11:17:37.055947624 -0600
@@ -0,0 +1,53 @@
+/************************************************************************
+ * Copyright 2003 Digi International (www.digi.com)
+ *
+ * Copyright (C) 2004 IBM Corporation. All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2, or (at your option)
+ * any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY, EXPRESS OR IMPLIED; without even the 
+ * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
+ * PURPOSE.  See the GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License 
+ * along with this program; if not, write to the Free Software 
+ * Foundation, Inc., 59 * Temple Place - Suite 330, Boston,
+ * MA  02111-1307, USA.
+ *
+ * Contact Information:
+ * Scott H Kilau <Scott_Kilau@digi.com>
+ * Wendy Xiong   <wendyx@us.ltcfwd.linux.ibm.com>
+ *
+ ***********************************************************************/
+#include <linux/device.h>
+#include <linux/serial_reg.h>
+
+#include "jsm_driver.h"
+
+static ssize_t jsm_driver_version_show(struct device_driver *ddp, char *buf)
+{
+	return snprintf(buf, PAGE_SIZE, "%s\n", JSM_VERSION);
+}
+static DRIVER_ATTR(version, S_IRUSR, jsm_driver_version_show, NULL);
+
+static ssize_t jsm_driver_state_show(struct device_driver *ddp, char *buf)
+{
+	return snprintf(buf, PAGE_SIZE, "%s\n", jsm_driver_state_text[jsm_driver_state]);
+}
+static DRIVER_ATTR(state, S_IRUSR, jsm_driver_state_show, NULL);
+
+void jsm_create_driver_sysfiles(struct device_driver *driverfs)
+{
+	driver_create_file(driverfs, &driver_attr_version);
+	driver_create_file(driverfs, &driver_attr_state);
+}
+
+void jsm_remove_driver_sysfiles(struct device_driver  *driverfs)
+{
+	driver_remove_file(driverfs, &driver_attr_version);
+	driver_remove_file(driverfs, &driver_attr_state);
+}

  reply	other threads:[~2005-03-09 17:20 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-27 23:39 [ patch 4/7] drivers/serial/jsm: new serial device driver Wen Xiong
2005-02-28  3:21 ` Christoph Hellwig
2005-02-28  6:39 ` Greg KH
2005-03-04 21:08   ` Wen Xiong
2005-03-04 22:01     ` Greg KH
2005-03-07 22:46       ` Wen Xiong
2005-03-08  6:44         ` Greg KH
2005-03-08 18:55           ` Wen Xiong
2005-03-08 23:58             ` Greg KH
2005-03-09 15:47               ` Wen Xiong
2005-03-09 16:35                 ` Greg KH
2005-03-09 17:18                   ` Wen Xiong [this message]
2005-03-09 18:58                     ` Greg KH
2005-03-11 15:29                       ` [ patch 1/5] " Wen Xiong
2005-03-12 13:06                         ` Domen Puncer
2005-03-14 17:35                           ` Wen Xiong
2005-03-14 20:24                             ` Domen Puncer
2005-03-14 21:24                               ` Wen Xiong
2005-03-11 15:32                       ` [ patch 2/5] " Wen Xiong
2005-03-30 14:55                         ` Russell King
2005-03-11 15:38                       ` [ patch 3/5] " Wen Xiong
2005-03-11 15:53                         ` Arjan van de Ven
2005-03-11 16:39                           ` Wen Xiong
2005-03-11 16:46                             ` Arjan van de Ven
2005-03-11 22:34                               ` Wen Xiong
2005-03-30 15:01                                 ` Russell King
2005-03-11 15:38                       ` [ patch 4/5] " Wen Xiong
2005-03-11 15:38                       ` [ patch 5/5] " Wen Xiong
2005-03-09 16:11           ` [ patch 4/7] " Russell King
  -- strict thread matches above, loose matches on Subject: below --
2005-03-08 21:47 Kilau, Scott
2005-03-09  0:02 ` Greg KH
2005-03-09 16:16 ` Russell King
2005-03-09  2:36 Kilau, Scott
2005-03-09  5:50 ` Greg KH

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=422F2FDD.4050908@us.ltcfwd.linux.ibm.com \
    --to=wendyx@us.ibm.com \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.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 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.