Showing error 543

User: Jiri Slaby
Error type: Calling function from invalid context
Error type description: Some function is called at inappropriate place like sleep inside critical sections or interrupt handlers
File location: drivers/scsi/aacraid/commsup.c
Line in file: 1182
Project: Linux Kernel
Project version: 2.6.28
Tools: Stanse (1.2)
Entered: 2011-11-07 22:19:02 UTC


Source:

1152         */
1153        host = aac->scsi_host_ptr;
1154        scsi_block_requests(host);
1155        aac_adapter_disable_int(aac);
1156        if (aac->thread->pid != current->pid) {
1157                spin_unlock_irq(host->host_lock);
1158                kthread_stop(aac->thread);
1159                jafo = 1;
1160        }
1161
1162        /*
1163         *        If a positive health, means in a known DEAD PANIC
1164         * state and the adapter could be reset to `try again'.
1165         */
1166        retval = aac_adapter_restart(aac, forced ? 0 : aac_adapter_check_health(aac));
1167
1168        if (retval)
1169                goto out;
1170
1171        /*
1172         *        Loop through the fibs, close the synchronous FIBS
1173         */
1174        for (retval = 1, index = 0; index < (aac->scsi_host_ptr->can_queue + AAC_NUM_MGT_FIB); index++) {
1175                struct fib *fib = &aac->fibs[index];
1176                if (!(fib->hw_fib_va->header.XferState & cpu_to_le32(NoResponseExpected | Async)) &&
1177                  (fib->hw_fib_va->header.XferState & cpu_to_le32(ResponseExpected))) {
1178                        unsigned long flagv;
1179                        spin_lock_irqsave(&fib->event_lock, flagv);
1180                        up(&fib->event_wait);
1181                        spin_unlock_irqrestore(&fib->event_lock, flagv);
1182                        schedule();
1183                        retval = 0;
1184                }
1185        }
1186        /* Give some extra time for ioctls to complete. */
1187        if (retval == 0)
1188                ssleep(2);
1189        index = aac->cardtype;
1190
1191        /*
1192         * Re-initialize the adapter, first free resources, then carefully
Show full sources