Showing error 574

User: Jiri Slaby
Error type: Double Lock
Error type description: Some lock is locked twice unintentionally in a sequence
File location: drivers/char/epca.c
Line in file: 2404
Project: Linux Kernel
Project version: 2.6.28
Confirmation: Driver removed in 4a6514e6d096716fb7bedf238efaaca877e2a7e8
Tools: Stanse (1.2)
Entered: 2011-11-07 22:19:59 UTC


Source:

2374        unsigned long flags;
2375        /*
2376         * verifyChannel returns the channel from the tty struct if it is
2377         * valid. This serves as a sanity check.
2378         */
2379        ch = verifyChannel(tty);
2380        if (ch != NULL) {
2381                spin_lock_irqsave(&epca_lock, flags);
2382                if ((ch->statusflags & TXSTOPPED) == 0) {
2383                        /* Begin if transmit stop requested */
2384                        globalwinon(ch);
2385                        /* STOP transmitting now !! */
2386                        fepcmd(ch, PAUSETX, 0, 0, 0, 0);
2387                        ch->statusflags |= TXSTOPPED;
2388                        memoff(ch);
2389                } /* End if transmit stop requested */
2390                spin_unlock_irqrestore(&epca_lock, flags);
2391        }
2392}
2393
2394static void pc_start(struct tty_struct *tty)
2395{
2396        struct channel *ch;
2397        /*
2398         * verifyChannel returns the channel from the tty struct if it is
2399         * valid. This serves as a sanity check.
2400         */
2401        ch = verifyChannel(tty);
2402        if (ch != NULL) {
2403                unsigned long flags;
2404                spin_lock_irqsave(&epca_lock, flags);
2405                /* Just in case output was resumed because of a change
2406                   in Digi-flow */
2407                if (ch->statusflags & TXSTOPPED)  {
2408                        /* Begin transmit resume requested */
2409                        struct board_chan __iomem *bc;
2410                        globalwinon(ch);
2411                        bc = ch->brdchan;
2412                        if (ch->statusflags & LOWWAIT)
2413                                writeb(1, &bc->ilow);
2414                        /* Okay, you can start transmitting again... */
Show full sources