>>>>> "Akinobu" == Akinobu Mita <akinobu.m...@gmail.com> writes:

Akinobu> In the module initialization, invalid value for guard module
Akinobu> parameter is detected by the following check:

Akinobu>         if (scsi_debug_guard > 1) {
Akinobu>                 printk(KERN_ERR "scsi_debug_init: guard must be
Akinobu>                 0 or 1\n"); return -EINVAL;
Akinobu>         }

Akinobu> But this check isn't enough, because the type of
Akinobu> scsi_debug_guard is 'int' and scsi_debug_guard could be a
Akinobu> negative value.

Akinobu> This fixes it by changing the type of scsi_debug_guard to
Akinobu> 'unsigned int' instead of adding extra check for a negative
Akinobu> value.

Acked-by: Martin K. Petersen <martin.peter...@oracle.com>

-- 
Martin K. Petersen      Oracle Linux Engineering
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to