[lkml]   [2007]   [Jul]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    Patch in this message
    Subject[patch 20/26] saa7134: fix thread shutdown handling
    -stable review patch.  If anyone has any objections, please let us know.


    From: Jeff Mahoney <>

    This patch changes the test for the thread pid from >= 0 to > 0.

    When the saa8134 driver initialization fails after a certain point, it goes
    through the complete shutdown process for the driver. Part of shutting it
    down includes tearing down the thread for tv audio.

    The test for tearing down the thread tests for >= 0. Since the dev
    structure is kzalloc'd, the test will always be true if we haven't tried to
    start the thread yet. We end up waiting on pid 0 to complete, which will
    never happen, so we lock up.

    This bug was observed in Novell Bugzilla 284718, when request_irq() failed.

    Signed-off-by: Jeff Mahoney <>
    Acked-by: Mauro Carvalho Chehab <>
    Signed-off-by: Andrew Morton <>
    Signed-off-by: Chris Wright <>
    Signed-off-by: Greg Kroah-Hartman <>

    drivers/media/video/saa7134/saa7134-tvaudio.c | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    --- linux-
    +++ linux-
    @@ -1006,7 +1006,7 @@ int saa7134_tvaudio_init2(struct saa7134
    int saa7134_tvaudio_fini(struct saa7134_dev *dev)
    /* shutdown tvaudio thread */
    - if (dev-> >= 0) {
    + if (dev-> > 0) {
    dev->thread.shutdown = 1;
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2007-07-31 06:41    [W:0.023 / U:19.836 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site