Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=21d364954f5a2a97b4e378f34a13fbf296aa16ec
Commit:     21d364954f5a2a97b4e378f34a13fbf296aa16ec
Parent:     b590d2baf17f8890f648e76436abdb8674d564eb
Author:     Tilman Schmidt <[EMAIL PROTECTED]>
AuthorDate: Tue May 8 20:27:03 2007 -0700
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Tue May 8 20:41:14 2007 -0700

    usb_gigaset: don't kmalloc(0)
    
    Zero-sized allocations are pointless anyway, and the SLUB allocator
    complains about them, so stop doing that.
    
    Signed-off-by: Tilman Schmidt <[EMAIL PROTECTED]>
    Signed-off-by: Hansjoerg Lipp <[EMAIL PROTECTED]>
    Cc: Greg KH <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
---
 drivers/isdn/gigaset/usb-gigaset.c |   14 ++++----------
 1 files changed, 4 insertions(+), 10 deletions(-)

diff --git a/drivers/isdn/gigaset/usb-gigaset.c 
b/drivers/isdn/gigaset/usb-gigaset.c
index c8e1c35..a126301 100644
--- a/drivers/isdn/gigaset/usb-gigaset.c
+++ b/drivers/isdn/gigaset/usb-gigaset.c
@@ -138,8 +138,6 @@ struct usb_cardstate {
        char                    bchars[6];              /* for request 0x19 */
 };
 
-struct usb_bc_state {};
-
 static inline unsigned tiocm_to_gigaset(unsigned state)
 {
        return ((state & TIOCM_DTR) ? 1 : 0) | ((state & TIOCM_RTS) ? 2 : 0);
@@ -579,25 +577,21 @@ static int gigaset_brkchars(struct cardstate *cs, const 
unsigned char buf[6])
 
 static int gigaset_freebcshw(struct bc_state *bcs)
 {
-       if (!bcs->hw.usb)
-               return 0;
-       //FIXME
-       kfree(bcs->hw.usb);
+       /* unused */
        return 1;
 }
 
 /* Initialize the b-channel structure */
 static int gigaset_initbcshw(struct bc_state *bcs)
 {
-       bcs->hw.usb = kmalloc(sizeof(struct usb_bc_state), GFP_KERNEL);
-       if (!bcs->hw.usb)
-               return 0;
-
+       /* unused */
+       bcs->hw.usb = NULL;
        return 1;
 }
 
 static void gigaset_reinitbcshw(struct bc_state *bcs)
 {
+       /* nothing to do for M10x */
 }
 
 static void gigaset_freecshw(struct cardstate *cs)
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to