* [PATCH 0/2] ISDN patches for 2.6.36
@ 2010-07-06 0:18 Tilman Schmidt
2010-07-06 0:18 ` [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment Tilman Schmidt
2010-07-06 0:18 ` [PATCH 2/2] isdn: avoid calling tty_ldisc_flush() in atomic context Tilman Schmidt
0 siblings, 2 replies; 6+ messages in thread
From: Tilman Schmidt @ 2010-07-06 0:18 UTC (permalink / raw)
To: Karsten Keil, David Miller
Cc: Hansjoerg Lipp, Karsten Keil, i4ldeveloper, netdev, linux-kernel
Karsten, David,
following are two patches to the ISDN subsystem I'd like to see
included in kernel release 2.6.36.
Thanks,
Tilman
Tilman Schmidt (2):
isdn: CAPI controller interface documentation amendment
isdn: avoid calling tty_ldisc_flush() in atomic context
Documentation/isdn/INTERFACE.CAPI | 8 ++++++--
drivers/isdn/i4l/isdn_tty.c | 6 ------
2 files changed, 6 insertions(+), 8 deletions(-)
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment
2010-07-06 0:18 [PATCH 0/2] ISDN patches for 2.6.36 Tilman Schmidt
@ 2010-07-06 0:18 ` Tilman Schmidt
2010-07-06 2:24 ` David Miller
2010-07-06 0:18 ` [PATCH 2/2] isdn: avoid calling tty_ldisc_flush() in atomic context Tilman Schmidt
1 sibling, 1 reply; 6+ messages in thread
From: Tilman Schmidt @ 2010-07-06 0:18 UTC (permalink / raw)
To: Karsten Keil, David Miller
Cc: Hansjoerg Lipp, Karsten Keil, i4ldeveloper, netdev, linux-kernel
Mention that the CAPI controller methods load_firmware() and
reset_ctr() are asynchronous, and should signal completion.
Impact: documentation
Signed-off-by: Tilman Schmidt <tilman@imap.cc>
---
Documentation/isdn/INTERFACE.CAPI | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/Documentation/isdn/INTERFACE.CAPI b/Documentation/isdn/INTERFACE.CAPI
index f172091..309eb5e 100644
--- a/Documentation/isdn/INTERFACE.CAPI
+++ b/Documentation/isdn/INTERFACE.CAPI
@@ -113,12 +113,16 @@ char *driver_name
int (*load_firmware)(struct capi_ctr *ctrlr, capiloaddata *ldata)
(optional) pointer to a callback function for sending firmware and
configuration data to the device
+ The function may return before the operation has completed.
+ Completion must be signalled by a call to capi_ctr_ready().
Return value: 0 on success, error code on error
Called in process context.
void (*reset_ctr)(struct capi_ctr *ctrlr)
- (optional) pointer to a callback function for performing a reset on
- the device, releasing all registered applications
+ (optional) pointer to a callback function for stopping the device,
+ releasing all registered applications
+ The function may return before the operation has completed.
+ Completion must be signalled by a call to capi_ctr_down().
Called in process context.
void (*register_appl)(struct capi_ctr *ctrlr, u16 applid,
--
1.6.5.3.298.g39add
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/2] isdn: avoid calling tty_ldisc_flush() in atomic context
2010-07-06 0:18 [PATCH 0/2] ISDN patches for 2.6.36 Tilman Schmidt
2010-07-06 0:18 ` [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment Tilman Schmidt
@ 2010-07-06 0:18 ` Tilman Schmidt
2010-07-06 2:24 ` David Miller
1 sibling, 1 reply; 6+ messages in thread
From: Tilman Schmidt @ 2010-07-06 0:18 UTC (permalink / raw)
To: Karsten Keil, David Miller
Cc: Hansjoerg Lipp, Karsten Keil, i4ldeveloper, netdev, linux-kernel,
stable
Remove the call to tty_ldisc_flush() from the RESULT_NO_CARRIER
branch of isdn_tty_modem_result(), as already proposed in commit
00409bb045887ec5e7b9e351bc080c38ab6bfd33.
This avoids a "sleeping function called from invalid context" BUG
when the hardware driver calls the statcallb() callback with
command==ISDN_STAT_DHUP in atomic context, which in turn calls
isdn_tty_modem_result(RESULT_NO_CARRIER, ~), and from there,
tty_ldisc_flush() which may sleep.
Impact: bugfix
Signed-off-by: Tilman Schmidt <tilman@imap.cc>
---
drivers/isdn/i4l/isdn_tty.c | 6 ------
1 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/drivers/isdn/i4l/isdn_tty.c b/drivers/isdn/i4l/isdn_tty.c
index fc8454d..51dc60d 100644
--- a/drivers/isdn/i4l/isdn_tty.c
+++ b/drivers/isdn/i4l/isdn_tty.c
@@ -2636,12 +2636,6 @@ isdn_tty_modem_result(int code, modem_info * info)
if ((info->flags & ISDN_ASYNC_CLOSING) || (!info->tty)) {
return;
}
-#ifdef CONFIG_ISDN_AUDIO
- if ( !info->vonline )
- tty_ldisc_flush(info->tty);
-#else
- tty_ldisc_flush(info->tty);
-#endif
if ((info->flags & ISDN_ASYNC_CHECK_CD) &&
(!((info->flags & ISDN_ASYNC_CALLOUT_ACTIVE) &&
(info->flags & ISDN_ASYNC_CALLOUT_NOHUP)))) {
--
1.6.5.3.298.g39add
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment
2010-07-06 0:18 ` [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment Tilman Schmidt
@ 2010-07-06 2:24 ` David Miller
2010-07-06 20:38 ` Tilman Schmidt
0 siblings, 1 reply; 6+ messages in thread
From: David Miller @ 2010-07-06 2:24 UTC (permalink / raw)
To: tilman; +Cc: isdn, hjlipp, keil, i4ldeveloper, netdev, linux-kernel
From: Tilman Schmidt <tilman@imap.cc>
Date: Tue, 6 Jul 2010 02:18:22 +0200 (CEST)
> Mention that the CAPI controller methods load_firmware() and
> reset_ctr() are asynchronous, and should signal completion.
>
> Impact: documentation
> Signed-off-by: Tilman Schmidt <tilman@imap.cc>
Applied to net-next-2.6
Please stop using "Impact: " tags, I just edit them out when
I add your changes.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] isdn: avoid calling tty_ldisc_flush() in atomic context
2010-07-06 0:18 ` [PATCH 2/2] isdn: avoid calling tty_ldisc_flush() in atomic context Tilman Schmidt
@ 2010-07-06 2:24 ` David Miller
0 siblings, 0 replies; 6+ messages in thread
From: David Miller @ 2010-07-06 2:24 UTC (permalink / raw)
To: tilman; +Cc: isdn, hjlipp, keil, i4ldeveloper, netdev, linux-kernel, stable
From: Tilman Schmidt <tilman@imap.cc>
Date: Tue, 6 Jul 2010 02:18:27 +0200 (CEST)
> Remove the call to tty_ldisc_flush() from the RESULT_NO_CARRIER
> branch of isdn_tty_modem_result(), as already proposed in commit
> 00409bb045887ec5e7b9e351bc080c38ab6bfd33.
> This avoids a "sleeping function called from invalid context" BUG
> when the hardware driver calls the statcallb() callback with
> command==ISDN_STAT_DHUP in atomic context, which in turn calls
> isdn_tty_modem_result(RESULT_NO_CARRIER, ~), and from there,
> tty_ldisc_flush() which may sleep.
>
> Impact: bugfix
> Signed-off-by: Tilman Schmidt <tilman@imap.cc>
Applied to net-next-2.6, thanks.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment
2010-07-06 2:24 ` David Miller
@ 2010-07-06 20:38 ` Tilman Schmidt
0 siblings, 0 replies; 6+ messages in thread
From: Tilman Schmidt @ 2010-07-06 20:38 UTC (permalink / raw)
To: David Miller; +Cc: isdn, hjlipp, keil, i4ldeveloper, netdev, linux-kernel
[-- Attachment #1: Type: text/plain, Size: 357 bytes --]
Am 06.07.2010 04:24 schrieb David Miller:
> Please stop using "Impact: " tags, I just edit them out when
> I add your changes.
Gladly.
Thanks,
Tilman
--
Tilman Schmidt E-Mail: tilman@imap.cc
Bonn, Germany
Diese Nachricht besteht zu 100% aus wiederverwerteten Bits.
Ungeöffnet mindestens haltbar bis: (siehe Rückseite)
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 259 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2010-07-06 20:38 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-06 0:18 [PATCH 0/2] ISDN patches for 2.6.36 Tilman Schmidt
2010-07-06 0:18 ` [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment Tilman Schmidt
2010-07-06 2:24 ` David Miller
2010-07-06 20:38 ` Tilman Schmidt
2010-07-06 0:18 ` [PATCH 2/2] isdn: avoid calling tty_ldisc_flush() in atomic context Tilman Schmidt
2010-07-06 2:24 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).