1. 10 Mar, 2024 11 commits
  2. 27 Feb, 2024 6 commits
  3. 15 Feb, 2024 2 commits
    • Arnd Bergmann's avatar
      scsi: csiostor: Avoid function pointer casts · 9f3dbcb5
      Arnd Bergmann authored
      csiostor uses function pointer casts to keep the csio_ln_ev state machine
      hidden, but this causes warnings about control flow integrity (KCFI)
      violations in clang-16 and higher:
      
      drivers/scsi/csiostor/csio_lnode.c:1098:33: error: cast from 'void (*)(struct csio_lnode *, enum csio_ln_ev)' to 'csio_sm_state_t' (aka 'void (*)(void *, unsigned int)') converts to incompatible function type [-Werror,-Wcast-function-type-strict]
       1098 |         return (csio_get_state(ln) == ((csio_sm_state_t)csio_lns_ready));
            |                                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      drivers/scsi/csiostor/csio_lnode.c:1369:29: error: cast from 'void (*)(struct csio_lnode *, enum csio_ln_ev)' to 'csio_sm_state_t' (aka 'void (*)(void *, unsigned int)') converts to incompatible function type [-Werror,-Wcast-function-type-strict]
       1369 |         if (csio_get_state(ln) == ((csio_sm_state_t)csio_lns_uninit)) {
            |                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      drivers/scsi/csiostor/csio_lnode.c:1373:29: error: cast from 'void (*)(struct csio_lnode *, enum csio_ln_ev)' to 'csio_sm_state_t' (aka 'void (*)(void *, unsigned int)') converts to incompatible function type [-Werror,-Wcast-function-type-strict]
       1373 |         if (csio_get_state(ln) == ((csio_sm_state_t)csio_lns_ready)) {
            |                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      drivers/scsi/csiostor/csio_lnode.c:1377:29: error: cast from 'void (*)(struct csio_lnode *, enum csio_ln_ev)' to 'csio_sm_state_t' (aka 'void (*)(void *, unsigned int)') converts to incompatible function type [-Werror,-Wcast-function-type-strict]
       1377 |         if (csio_get_state(ln) == ((csio_sm_state_t)csio_lns_offline)) {
            |                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      
      Move the enum into a shared header so the correct types can be used without
      the need for casts.
      
      Fixes: a3667aae ("[SCSI] csiostor: Chelsio FCoE offload driver")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Link: https://lore.kernel.org/r/20240213100518.457623-1-arnd@kernel.orgSigned-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
      9f3dbcb5
    • Colin Ian King's avatar
      scsi: qla1280: Remove redundant assignment to variable 'mr' · b628db42
      Colin Ian King authored
      The variable 'mr' being assigned a value that is never read, the assignment
      is redundant and can be removed.
      
      Cleans up clang scan build warning:
      
      drivers/scsi/qla1280.c:2481:2: warning: Value stored to 'mr' is never
      read [deadcode.DeadStores]
      Signed-off-by: default avatarColin Ian King <colin.i.king@gmail.com>
      Link: https://lore.kernel.org/r/20240215153533.2067413-1-colin.i.king@gmail.comSigned-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
      b628db42
  4. 13 Feb, 2024 2 commits
  5. 06 Feb, 2024 19 commits