Re: block_til_ready

2007-03-08 Thread Eric Dumazet

Mockern a écrit :

Hi,

What is the simpliest implementation of block_til_ready for tty driver?

Thanks,

Andy


Welcome Andy

Since your messages always make me wonder if you are some kind of robot, able 
to post one "one line" message to lkml everyday, I have one suggestion :


Try next times to build messages with a detailed context, so that eventually 
one reader of this messages might care, possibly *understand* your question, 
and thus be able to possibly help you and others as well.


For example, an url to your sources, even if a 'not yet working' state, would 
be very nice.


Have a nice day
Eric

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


block_til_ready

2007-03-08 Thread Mockern
Hi,

What is the simpliest implementation of block_til_ready for tty driver?

Thanks,

Andy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH] generic_serial's block_til_ready

2000-12-15 Thread Patrick van de Lageweg

Hi Linus,
 
This patch renames the block_til_ready of generic serial to
gs_block_til_ready. 

it helps when other modules have a "static block_til_ready" defined when
used older modutils.

Patrick

diff -u -r linux-2.4.0-test13-pre1.clean/drivers/char/generic_serial.c 
linux-2.4.0-test13-pre1.block_til_ready/drivers/char/generic_serial.c
--- linux-2.4.0-test13-pre1.clean/drivers/char/generic_serial.c Thu Nov 16 21:51:27 
2000
+++ linux-2.4.0-test13-pre1.block_til_ready/drivers/char/generic_serial.c   Thu 
+Dec 14 09:48:05 2000
@@ -35,7 +35,6 @@
 
 static int gs_debug;
 
-
 #ifdef DEBUG
 #define gs_dprintk(f, str...) if (gs_debug & f) printk (str)
 #else
@@ -583,7 +582,7 @@
 }
 
 
-int block_til_ready(void *port_, struct file * filp)
+int gs_block_til_ready(void *port_, struct file * filp)
 {
struct gs_port *port = port_;
DECLARE_WAITQUEUE(wait, current);
@@ -600,7 +599,7 @@
 
if (!tty) return 0;
 
-   gs_dprintk (GS_DEBUG_BTR, "Entering block_till_ready.\n"); 
+   gs_dprintk (GS_DEBUG_BTR, "Entering gs_block_till_ready.\n"); 
/*
 * If the device is in the middle of being closed, then block
 * until it's done, and then try again.
@@ -1070,7 +1069,7 @@
 EXPORT_SYMBOL(gs_start);
 EXPORT_SYMBOL(gs_hangup);
 EXPORT_SYMBOL(gs_do_softint);
-EXPORT_SYMBOL(block_til_ready);
+EXPORT_SYMBOL(gs_block_til_ready);
 EXPORT_SYMBOL(gs_close);
 EXPORT_SYMBOL(gs_set_termios);
 EXPORT_SYMBOL(gs_init_port);
diff -u -r linux-2.4.0-test13-pre1.clean/drivers/char/sh-sci.c 
linux-2.4.0-test13-pre1.block_til_ready/drivers/char/sh-sci.c
--- linux-2.4.0-test13-pre1.clean/drivers/char/sh-sci.c Thu Oct 12 23:20:47 2000
+++ linux-2.4.0-test13-pre1.block_til_ready/drivers/char/sh-sci.c   Thu Dec 14 
+09:48:05 2000
@@ -839,7 +839,7 @@
MOD_INC_USE_COUNT;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
 
if (retval) {
MOD_DEC_USE_COUNT;
diff -u -r linux-2.4.0-test13-pre1.clean/drivers/char/sx.c 
linux-2.4.0-test13-pre1.block_til_ready/drivers/char/sx.c
--- linux-2.4.0-test13-pre1.clean/drivers/char/sx.c Thu Nov 16 21:51:27 2000
+++ linux-2.4.0-test13-pre1.block_til_ready/drivers/char/sx.c   Thu Dec 14 09:48:05 
+2000
@@ -1478,7 +1478,7 @@
return -EIO;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
sx_dprintk (SX_DEBUG_OPEN, "Block til ready returned %d. Count=%d\n", 
retval, port->gs.count);
 
diff -u -r linux-2.4.0-test13-pre1.clean/drivers/char/vme_scc.c 
linux-2.4.0-test13-pre1.block_til_ready/drivers/char/vme_scc.c
--- linux-2.4.0-test13-pre1.clean/drivers/char/vme_scc.cFri Dec 15 12:53:04 
2000
+++ linux-2.4.0-test13-pre1.block_til_ready/drivers/char/vme_scc.c  Fri Dec 15 
+12:53:34 2000
@@ -933,7 +933,7 @@
if (port->gs.count == 1) {
    MOD_INC_USE_COUNT;
}
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
 
if (retval) {
MOD_DEC_USE_COUNT;
diff -u -r linux-2.4.0-test13-pre1.clean/include/linux/generic_serial.h 
linux-2.4.0-test13-pre1.block_til_ready/include/linux/generic_serial.h
--- linux-2.4.0-test13-pre1.clean/include/linux/generic_serial.h    Mon Mar 13 
04:18:55 2000
+++ linux-2.4.0-test13-pre1.block_til_ready/include/linux/generic_serial.h  Thu 
+Dec 14 09:48:05 2000
@@ -92,7 +92,7 @@
 void gs_start(struct tty_struct *tty);
 void gs_hangup(struct tty_struct *tty);
 void gs_do_softint(void *private_);
-int  block_til_ready(void *port, struct file *filp);
+int  gs_block_til_ready(void *port, struct file *filp);
 void gs_close(struct tty_struct *tty, struct file *filp);
 void gs_set_termios (struct tty_struct * tty, 
  struct termios * old_termios);




-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



Re: [PATCH] generic_serial's block_til_ready

2000-12-12 Thread Jeff Garzik

Nick Holloway wrote:
> 
> [EMAIL PROTECTED] (Patrick van de Lageweg) writes:
> > This patch renames the block_til_ready of generic serial to
> > gs_block_til_ready.
> >
> > it helps when other modules have a "static block_til_ready" defined when
> > used older modutils.
> 
> Do you mean older than the version specified as being required in
> Documention/CHANGES?
> 
> If so, then I'm not surprised the patch has not been applied (how many
> times have you sent it?).

His patch is a namespace cleanup, which IMHO should be applied...

Jeff


-- 
Jeff Garzik |
Building 1024   | These are not the J's you're lookin' for.
MandrakeSoft| It's an old Jedi mind trick.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



Re: [PATCH] generic_serial's block_til_ready

2000-12-12 Thread Nick Holloway

[EMAIL PROTECTED] (Patrick van de Lageweg) writes:
> This patch renames the block_til_ready of generic serial to
> gs_block_til_ready. 
> 
> it helps when other modules have a "static block_til_ready" defined when
> used older modutils.

Do you mean older than the version specified as being required in
Documention/CHANGES?

If so, then I'm not surprised the patch has not been applied (how many
times have you sent it?).

-- 
 `O O'  | [EMAIL PROTECTED]
// ^ \\ | http://www.pyrites.org.uk/
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



[PATCH] generic_serial's block_til_ready

2000-12-12 Thread Patrick van de Lageweg

Hi Linus,
 
This patch renames the block_til_ready of generic serial to
gs_block_til_ready. 

it helps when other modules have a "static block_til_ready" defined when
used older modutils.

Patrick


diff -r -u linux-2.4.0-test10.clean/drivers/char/generic_serial.c 
linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c
--- linux-2.4.0-test10.clean/drivers/char/generic_serial.c  Tue Nov 21 12:08:20 
2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c Tue Nov 21 
+12:31:43 2000
@@ -35,7 +35,6 @@
 
 static int gs_debug;
 
-
 #ifdef DEBUG
 #define gs_dprintk(f, str...) if (gs_debug & f) printk (str)
 #else
@@ -583,7 +582,7 @@
 }
 
 
-int block_til_ready(void *port_, struct file * filp)
+int gs_block_til_ready(void *port_, struct file * filp)
 {
struct gs_port *port = port_;
DECLARE_WAITQUEUE(wait, current);
@@ -600,7 +599,7 @@
 
if (!tty) return 0;
 
-   gs_dprintk (GS_DEBUG_BTR, "Entering block_till_ready.\n"); 
+   gs_dprintk (GS_DEBUG_BTR, "Entering gs_block_till_ready.\n"); 
/*
 * If the device is in the middle of being closed, then block
 * until it's done, and then try again.
@@ -1070,7 +1069,7 @@
 EXPORT_SYMBOL(gs_start);
 EXPORT_SYMBOL(gs_hangup);
 EXPORT_SYMBOL(gs_do_softint);
-EXPORT_SYMBOL(block_til_ready);
+EXPORT_SYMBOL(gs_block_til_ready);
 EXPORT_SYMBOL(gs_close);
 EXPORT_SYMBOL(gs_set_termios);
 EXPORT_SYMBOL(gs_init_port);
diff -r -u linux-2.4.0-test10.clean/drivers/char/sh-sci.c 
linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c
--- linux-2.4.0-test10.clean/drivers/char/sh-sci.c  Wed Nov  1 13:57:19 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c Tue Nov 21 12:13:56 
+2000
@@ -839,7 +839,7 @@
MOD_INC_USE_COUNT;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
 
if (retval) {
MOD_DEC_USE_COUNT;
diff -r -u linux-2.4.0-test10.clean/drivers/char/sx.c 
linux-2.4.0-test10.generic_serial/drivers/char/sx.c
--- linux-2.4.0-test10.clean/drivers/char/sx.c  Tue Nov 21 12:08:21 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sx.c Tue Nov 21 12:13:56 2000
@@ -1478,7 +1478,7 @@
return -EIO;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
sx_dprintk (SX_DEBUG_OPEN, "Block til ready returned %d. Count=%d\n", 
retval, port->gs.count);
 
diff -r -u linux-2.4.0-test10.clean/include/linux/generic_serial.h 
linux-2.4.0-test10.generic_serial/include/linux/generic_serial.h
--- linux-2.4.0-test10.clean/include/linux/generic_serial.h Mon Mar 13 04:18:55 
2000
+++ linux-2.4.0-test10.generic_serial/include/linux/generic_serial.hTue Nov 21 
+12:13:56 2000
@@ -92,7 +92,7 @@
 void gs_start(struct tty_struct *tty);
 void gs_hangup(struct tty_struct *tty);
 void gs_do_softint(void *private_);
-int  block_til_ready(void *port, struct file *filp);
+int  gs_block_til_ready(void *port, struct file *filp);
 void gs_close(struct tty_struct *tty, struct file *filp);
 void gs_set_termios (struct tty_struct * tty, 
  struct termios * old_termios);






-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



[PATCH] generic_serial's block_til_ready

2000-12-06 Thread Patrick van de Lageweg

Hi Linus,
 
This patch renames the block_til_ready of generic serial to
gs_block_til_ready. 

it helps when other modules have a "static block_til_ready" defined when
used older modutils.

Patrick


diff -r -u linux-2.4.0-test10.clean/drivers/char/generic_serial.c 
linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c
--- linux-2.4.0-test10.clean/drivers/char/generic_serial.c  Tue Nov 21 12:08:20 
2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c Tue Nov 21 
+12:31:43 2000
@@ -35,7 +35,6 @@
 
 static int gs_debug;
 
-
 #ifdef DEBUG
 #define gs_dprintk(f, str...) if (gs_debug & f) printk (str)
 #else
@@ -583,7 +582,7 @@
 }
 
 
-int block_til_ready(void *port_, struct file * filp)
+int gs_block_til_ready(void *port_, struct file * filp)
 {
struct gs_port *port = port_;
DECLARE_WAITQUEUE(wait, current);
@@ -600,7 +599,7 @@
 
if (!tty) return 0;
 
-   gs_dprintk (GS_DEBUG_BTR, "Entering block_till_ready.\n"); 
+   gs_dprintk (GS_DEBUG_BTR, "Entering gs_block_till_ready.\n"); 
/*
 * If the device is in the middle of being closed, then block
 * until it's done, and then try again.
@@ -1070,7 +1069,7 @@
 EXPORT_SYMBOL(gs_start);
 EXPORT_SYMBOL(gs_hangup);
 EXPORT_SYMBOL(gs_do_softint);
-EXPORT_SYMBOL(block_til_ready);
+EXPORT_SYMBOL(gs_block_til_ready);
 EXPORT_SYMBOL(gs_close);
 EXPORT_SYMBOL(gs_set_termios);
 EXPORT_SYMBOL(gs_init_port);
diff -r -u linux-2.4.0-test10.clean/drivers/char/sh-sci.c 
linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c
--- linux-2.4.0-test10.clean/drivers/char/sh-sci.c  Wed Nov  1 13:57:19 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c Tue Nov 21 12:13:56 
+2000
@@ -839,7 +839,7 @@
MOD_INC_USE_COUNT;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
 
if (retval) {
MOD_DEC_USE_COUNT;
diff -r -u linux-2.4.0-test10.clean/drivers/char/sx.c 
linux-2.4.0-test10.generic_serial/drivers/char/sx.c
--- linux-2.4.0-test10.clean/drivers/char/sx.c  Tue Nov 21 12:08:21 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sx.c Tue Nov 21 12:13:56 2000
@@ -1478,7 +1478,7 @@
return -EIO;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
sx_dprintk (SX_DEBUG_OPEN, "Block til ready returned %d. Count=%d\n", 
retval, port->gs.count);
 
diff -r -u linux-2.4.0-test10.clean/include/linux/generic_serial.h 
linux-2.4.0-test10.generic_serial/include/linux/generic_serial.h
--- linux-2.4.0-test10.clean/include/linux/generic_serial.h Mon Mar 13 04:18:55 
2000
+++ linux-2.4.0-test10.generic_serial/include/linux/generic_serial.hTue Nov 21 
+12:13:56 2000
@@ -92,7 +92,7 @@
 void gs_start(struct tty_struct *tty);
 void gs_hangup(struct tty_struct *tty);
 void gs_do_softint(void *private_);
-int  block_til_ready(void *port, struct file *filp);
+int  gs_block_til_ready(void *port, struct file *filp);
 void gs_close(struct tty_struct *tty, struct file *filp);
 void gs_set_termios (struct tty_struct * tty, 
  struct termios * old_termios);





-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



[PATCH] generic_serial's block_til_ready

2000-11-30 Thread Patrick van de Lageweg

Hi Linus,
 
This patch renames the block_til_ready of generic serial to
gs_block_til_ready. 

it helps when other modules have a "static block_til_ready" defined when
used older modutils.

Patrick


diff -r -u linux-2.4.0-test10.clean/drivers/char/generic_serial.c 
linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c
--- linux-2.4.0-test10.clean/drivers/char/generic_serial.c  Tue Nov 21 12:08:20 
2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c Tue Nov 21 
+12:31:43 2000
@@ -35,7 +35,6 @@
 
 static int gs_debug;
 
-
 #ifdef DEBUG
 #define gs_dprintk(f, str...) if (gs_debug & f) printk (str)
 #else
@@ -583,7 +582,7 @@
 }
 
 
-int block_til_ready(void *port_, struct file * filp)
+int gs_block_til_ready(void *port_, struct file * filp)
 {
struct gs_port *port = port_;
DECLARE_WAITQUEUE(wait, current);
@@ -600,7 +599,7 @@
 
if (!tty) return 0;
 
-   gs_dprintk (GS_DEBUG_BTR, "Entering block_till_ready.\n"); 
+   gs_dprintk (GS_DEBUG_BTR, "Entering gs_block_till_ready.\n"); 
/*
 * If the device is in the middle of being closed, then block
 * until it's done, and then try again.
@@ -1070,7 +1069,7 @@
 EXPORT_SYMBOL(gs_start);
 EXPORT_SYMBOL(gs_hangup);
 EXPORT_SYMBOL(gs_do_softint);
-EXPORT_SYMBOL(block_til_ready);
+EXPORT_SYMBOL(gs_block_til_ready);
 EXPORT_SYMBOL(gs_close);
 EXPORT_SYMBOL(gs_set_termios);
 EXPORT_SYMBOL(gs_init_port);
diff -r -u linux-2.4.0-test10.clean/drivers/char/sh-sci.c 
linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c
--- linux-2.4.0-test10.clean/drivers/char/sh-sci.c  Wed Nov  1 13:57:19 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c Tue Nov 21 12:13:56 
+2000
@@ -839,7 +839,7 @@
MOD_INC_USE_COUNT;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
 
if (retval) {
MOD_DEC_USE_COUNT;
diff -r -u linux-2.4.0-test10.clean/drivers/char/sx.c 
linux-2.4.0-test10.generic_serial/drivers/char/sx.c
--- linux-2.4.0-test10.clean/drivers/char/sx.c  Tue Nov 21 12:08:21 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sx.c Tue Nov 21 12:13:56 2000
@@ -1478,7 +1478,7 @@
return -EIO;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
sx_dprintk (SX_DEBUG_OPEN, "Block til ready returned %d. Count=%d\n", 
retval, port->gs.count);
 
diff -r -u linux-2.4.0-test10.clean/include/linux/generic_serial.h 
linux-2.4.0-test10.generic_serial/include/linux/generic_serial.h
--- linux-2.4.0-test10.clean/include/linux/generic_serial.h Mon Mar 13 04:18:55 
2000
+++ linux-2.4.0-test10.generic_serial/include/linux/generic_serial.hTue Nov 21 
+12:13:56 2000
@@ -92,7 +92,7 @@
 void gs_start(struct tty_struct *tty);
 void gs_hangup(struct tty_struct *tty);
 void gs_do_softint(void *private_);
-int  block_til_ready(void *port, struct file *filp);
+int  gs_block_til_ready(void *port, struct file *filp);
 void gs_close(struct tty_struct *tty, struct file *filp);
 void gs_set_termios (struct tty_struct * tty, 
  struct termios * old_termios);


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



[PATCH] generic_serial's block_til_ready

2000-11-21 Thread Patrick van de Lageweg

Hi Linus,
 
This patch renames the block_til_ready of generic serial to
gs_block_til_ready. 

it helps when other modules have a "static block_til_ready" defined when
used older modutils.

Patrick


diff -r -u linux-2.4.0-test10.clean/drivers/char/generic_serial.c 
linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c
--- linux-2.4.0-test10.clean/drivers/char/generic_serial.c  Tue Nov 21 12:08:20 
2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/generic_serial.c Tue Nov 21 
+12:31:43 2000
@@ -35,7 +35,6 @@
 
 static int gs_debug;
 
-
 #ifdef DEBUG
 #define gs_dprintk(f, str...) if (gs_debug & f) printk (str)
 #else
@@ -583,7 +582,7 @@
 }
 
 
-int block_til_ready(void *port_, struct file * filp)
+int gs_block_til_ready(void *port_, struct file * filp)
 {
struct gs_port *port = port_;
DECLARE_WAITQUEUE(wait, current);
@@ -600,7 +599,7 @@
 
if (!tty) return 0;
 
-   gs_dprintk (GS_DEBUG_BTR, "Entering block_till_ready.\n"); 
+   gs_dprintk (GS_DEBUG_BTR, "Entering gs_block_till_ready.\n"); 
/*
 * If the device is in the middle of being closed, then block
 * until it's done, and then try again.
@@ -1070,7 +1069,7 @@
 EXPORT_SYMBOL(gs_start);
 EXPORT_SYMBOL(gs_hangup);
 EXPORT_SYMBOL(gs_do_softint);
-EXPORT_SYMBOL(block_til_ready);
+EXPORT_SYMBOL(gs_block_til_ready);
 EXPORT_SYMBOL(gs_close);
 EXPORT_SYMBOL(gs_set_termios);
 EXPORT_SYMBOL(gs_init_port);
diff -r -u linux-2.4.0-test10.clean/drivers/char/sh-sci.c 
linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c
--- linux-2.4.0-test10.clean/drivers/char/sh-sci.c  Wed Nov  1 13:57:19 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sh-sci.c Tue Nov 21 12:13:56 
+2000
@@ -839,7 +839,7 @@
MOD_INC_USE_COUNT;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
 
if (retval) {
MOD_DEC_USE_COUNT;
diff -r -u linux-2.4.0-test10.clean/drivers/char/sx.c 
linux-2.4.0-test10.generic_serial/drivers/char/sx.c
--- linux-2.4.0-test10.clean/drivers/char/sx.c  Tue Nov 21 12:08:21 2000
+++ linux-2.4.0-test10.generic_serial/drivers/char/sx.c Tue Nov 21 12:13:56 2000
@@ -1478,7 +1478,7 @@
return -EIO;
    }
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
sx_dprintk (SX_DEBUG_OPEN, "Block til ready returned %d. Count=%d\n", 
retval, port->gs.count);
 
diff -r -u linux-2.4.0-test10.clean/include/linux/generic_serial.h 
linux-2.4.0-test10.generic_serial/include/linux/generic_serial.h
--- linux-2.4.0-test10.clean/include/linux/generic_serial.h Mon Mar 13 04:18:55 
2000
+++ linux-2.4.0-test10.generic_serial/include/linux/generic_serial.hTue Nov 21 
+12:13:56 2000
@@ -92,7 +92,7 @@
 void gs_start(struct tty_struct *tty);
 void gs_hangup(struct tty_struct *tty);
 void gs_do_softint(void *private_);
-int  block_til_ready(void *port, struct file *filp);
+int  gs_block_til_ready(void *port, struct file *filp);
 void gs_close(struct tty_struct *tty, struct file *filp);
 void gs_set_termios (struct tty_struct * tty, 
  struct termios * old_termios);

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



Re: [PATCH] generic_serial's block_til_ready (fwd)

2000-10-27 Thread Keith Owens

On Fri, 27 Oct 2000 15:27:04 +0200 (CEST), 
Patrick van de Lageweg <[EMAIL PROTECTED]> wrote:
>This patch renames the block_til_ready of generic serial to
>gs_block_til_ready. This patch also exports the symbols needed by other
>modules with generic_serial compiled into the kernel.
>
>(it also helps when other modules have a "static block_til_ready"
>defined. This IMHO is a bug in the module-utils, but I'm told it
>cannot be fixed becuase of backwards compatibility Grrr. -- REW)

modutils for kernel 2.5 will break that backwards compatibility, it
goes all the way back to 2.0 kernels.  But if I broke backwards
compatibility just before 2.4 kernel release, there would be a lynch
mob headed my way.  In any case, block_til_ready is too generic a name
for an exported symbol.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/



[PATCH] generic_serial's block_til_ready (fwd)

2000-10-27 Thread Patrick van de Lageweg

Hi Linus,

This patch renames the block_til_ready of generic serial to
gs_block_til_ready. This patch also exports the symbols needed by other
modules with generic_serial compiled into the kernel.

(it also helps when other modules have a "static block_til_ready"
defined. This IMHO is a bug in the module-utils, but I'm told it
cannot be fixed becuase of backwards compatibility Grrr. -- REW)


Patrick

diff -u -r linux-2.4.0-test10-pre6.clean/drivers/char/generic_serial.c 
linux-2.4.0-test10-pre6.block_til_ready/drivers/char/generic_serial.c
--- linux-2.4.0-test10-pre6.clean/drivers/char/generic_serial.c Fri Oct 27 12:57:09 
2000
+++ linux-2.4.0-test10-pre6.block_til_ready/drivers/char/generic_serial.c   Fri 
+Oct 27 14:36:44 2000
@@ -61,6 +61,23 @@
 MODULE_PARM(gs_debug, "i");
 #endif
 
+EXPORT_SYMBOL(gs_set_termios);
+EXPORT_SYMBOL(gs_chars_in_buffer);
+EXPORT_SYMBOL(gs_write);
+EXPORT_SYMBOL(gs_close);
+EXPORT_SYMBOL(gs_put_char);
+EXPORT_SYMBOL(gs_flush_chars);
+EXPORT_SYMBOL(gs_debug);
+EXPORT_SYMBOL(gs_hangup);
+EXPORT_SYMBOL(gs_stop);
+EXPORT_SYMBOL(gs_flush_buffer);
+EXPORT_SYMBOL(gs_init_port);
+EXPORT_SYMBOL(gs_write_room);
+EXPORT_SYMBOL(gs_start);
+EXPORT_SYMBOL(gs_setserial);
+EXPORT_SYMBOL(gs_getserial);
+EXPORT_SYMBOL(gs_block_til_ready);
+
 #ifdef DEBUG
 static void my_hd (unsigned char *addr, int len)
 {
@@ -606,7 +623,7 @@
 }
 
 
-int block_til_ready(void *port_, struct file * filp)
+int gs_block_til_ready(void *port_, struct file * filp)
 {
struct gs_port *port = port_;
DECLARE_WAITQUEUE(wait, current);
@@ -623,7 +640,7 @@
 
if (!tty) return 0;
 
-   gs_dprintk (GS_DEBUG_BTR, "Entering block_till_ready.\n"); 
+   gs_dprintk (GS_DEBUG_BTR, "Entering gs_block_till_ready.\n"); 
/*
 * If the device is in the middle of being closed, then block
 * until it's done, and then try again.
diff -u -r linux-2.4.0-test10-pre6.clean/drivers/char/sh-sci.c 
linux-2.4.0-test10-pre6.block_til_ready/drivers/char/sh-sci.c
--- linux-2.4.0-test10-pre6.clean/drivers/char/sh-sci.c Fri Oct 27 12:57:13 2000
+++ linux-2.4.0-test10-pre6.block_til_ready/drivers/char/sh-sci.c   Fri Oct 27 
+14:42:19 2000
@@ -839,7 +839,7 @@
    MOD_INC_USE_COUNT;
}
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
 
if (retval) {
MOD_DEC_USE_COUNT;
diff -u -r linux-2.4.0-test10-pre6.clean/drivers/char/sx.c 
linux-2.4.0-test10-pre6.block_til_ready/drivers/char/sx.c
--- linux-2.4.0-test10-pre6.clean/drivers/char/sx.c Fri Oct 27 12:57:14 2000
+++ linux-2.4.0-test10-pre6.block_til_ready/drivers/char/sx.c   Fri Oct 27 14:38:46 
+2000
@@ -1478,7 +1478,7 @@
return -EIO;
}
 
-   retval = block_til_ready(port, filp);
+   retval = gs_block_til_ready(port, filp);
sx_dprintk (SX_DEBUG_OPEN, "Block til ready returned %d. Count=%d\n", 
retval, port->gs.count);
 
diff -u -r linux-2.4.0-test10-pre6.clean/include/linux/generic_serial.h 
linux-2.4.0-test10-pre6.block_til_ready/include/linux/generic_serial.h
--- linux-2.4.0-test10-pre6.clean/include/linux/generic_serial.hMon Mar 13 
04:18:55 2000
+++ linux-2.4.0-test10-pre6.block_til_ready/include/linux/generic_serial.h  Fri 
+Oct 27 14:10:49 2000
@@ -92,7 +92,7 @@
 void gs_start(struct tty_struct *tty);
 void gs_hangup(struct tty_struct *tty);
 void gs_do_softint(void *private_);
-int  block_til_ready(void *port, struct file *filp);
+int  gs_block_til_ready(void *port, struct file *filp);
 void gs_close(struct tty_struct *tty, struct file *filp);
 void gs_set_termios (struct tty_struct * tty, 
  struct termios * old_termios);


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.tux.org/lkml/