On Mon, Aug 1, 2022 at 4:55 PM Hans de Goede <hdegoede@xxxxxxxxxx> wrote: > > The local status variables in intel_vsec_pci_error_detected() > and intel_vsec_pci_slot_reset() should have pci_ers_result_t as type > (and not pci_channel_state_t). > > Also fix a whitespace error as well as intel_vsec_pci_err_handlers not > being marked static. > > This fixes the following sparse errors: > > drivers/platform/x86/intel/vsec.c:429:38: sparse: sparse: incorrect type in initializer (different base types) @@ expected restricted pci_channel_state_t [usertype] status @@ got restricted pci_ers_result_t @@ > drivers/platform/x86/intel/vsec.c:429:38: sparse: expected restricted pci_channel_state_t [usertype] status > drivers/platform/x86/intel/vsec.c:429:38: sparse: got restricted pci_ers_result_t > drivers/platform/x86/intel/vsec.c:434:24: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted pci_channel_state_t [usertype] status @@ got restricted pci_ers_result_t @@ Can we just instead show only a single case per type of the sparse errors so we reduce the noise in the commit message? Or another variants on compressing this text somehow? > drivers/platform/x86/intel/vsec.c:434:24: sparse: expected restricted pci_channel_state_t [usertype] status > drivers/platform/x86/intel/vsec.c:434:24: sparse: got restricted pci_ers_result_t > drivers/platform/x86/intel/vsec.c:438:16: sparse: sparse: incorrect type in return expression (different base types) @@ expected restricted pci_ers_result_t @@ got restricted pci_channel_state_t [usertype] status @@ > drivers/platform/x86/intel/vsec.c:438:16: sparse: expected restricted pci_ers_result_t > drivers/platform/x86/intel/vsec.c:438:16: sparse: got restricted pci_channel_state_t [usertype] status > drivers/platform/x86/intel/vsec.c:444:38: sparse: sparse: incorrect type in initializer (different base types) @@ expected restricted pci_channel_state_t [usertype] status @@ got restricted pci_ers_result_t @@ > drivers/platform/x86/intel/vsec.c:444:38: sparse: expected restricted pci_channel_state_t [usertype] status > drivers/platform/x86/intel/vsec.c:444:38: sparse: got restricted pci_ers_result_t > drivers/platform/x86/intel/vsec.c:457:16: sparse: sparse: incorrect type in assignment (different base types) @@ expected restricted pci_channel_state_t [usertype] status @@ got restricted pci_ers_result_t @@ > drivers/platform/x86/intel/vsec.c:457:16: sparse: expected restricted pci_channel_state_t [usertype] status > drivers/platform/x86/intel/vsec.c:457:16: sparse: got restricted pci_ers_result_t > drivers/platform/x86/intel/vsec.c:472:16: sparse: sparse: incorrect type in return expression (different base types) @@ expected restricted pci_ers_result_t @@ got restricted pci_channel_state_t [usertype] status @@ > drivers/platform/x86/intel/vsec.c:472:16: sparse: expected restricted pci_ers_result_t > drivers/platform/x86/intel/vsec.c:472:16: sparse: got restricted pci_channel_state_t [usertype] status > drivers/platform/x86/intel/vsec.c:480:33: sparse: sparse: symbol 'intel_vsec_pci_err_handlers' was not declared. Should it be static? Code looks good to me. Reviewed-by: Andy Shevchenko <andy.shevchenko@xxxxxxxxx> -- With Best Regards, Andy Shevchenko