CC: [email protected]
In-Reply-To: <[email protected]>
References: <[email protected]>
TO: "Chia-Wei Wang" <[email protected]>
TO: [email protected]
TO: [email protected]
TO: [email protected]
TO: [email protected]
TO: [email protected]
TO: [email protected]
TO: [email protected]
TO: [email protected]
TO: [email protected]

Hi Chia-Wei,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on joel-aspeed/for-next]
[also build test WARNING on v5.14-rc5 next-20210813]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    
https://github.com/0day-ci/linux/commits/Chia-Wei-Wang/aspeed-Add-LPC-mailbox-support/20210813-134908
base:   https://git.kernel.org/pub/scm/linux/kernel/git/joel/aspeed.git for-next
:::::: branch date: 3 days ago
:::::: commit date: 3 days ago
config: openrisc-randconfig-m031-20210816 (attached as .config)
compiler: or1k-linux-gcc (GCC) 11.2.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <[email protected]>
Reported-by: Dan Carpenter <[email protected]>

smatch warnings:
drivers/soc/aspeed/aspeed-lpc-mbox.c:230 aspeed_mbox_ioctl() warn: maybe return 
-EFAULT instead of the bytes remaining?

vim +230 drivers/soc/aspeed/aspeed-lpc-mbox.c

72c5a69dc779f5 Chia-Wei Wang 2021-08-13  213  
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  214  static long 
aspeed_mbox_ioctl(struct file *file, unsigned int cmd,
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  215                             
unsigned long param)
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  216  {
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  217    struct aspeed_mbox *mbox = 
file_mbox(file);
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  218    const struct aspeed_mbox_model 
*model = mbox->model;
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  219    struct aspeed_mbox_ioctl_data 
data;
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  220    long ret;
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  221  
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  222    switch (cmd) {
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  223    case ASPEED_MBOX_IOCTL_GET_SIZE:
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  224            data.data = 
model->dr_num;
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  225            ret = 
copy_to_user((void __user *)param, &data, sizeof(data));
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  226            break;
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  227    default:
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  228            ret = -ENOTTY;
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  229    }
72c5a69dc779f5 Chia-Wei Wang 2021-08-13 @230    return ret;
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  231  }
72c5a69dc779f5 Chia-Wei Wang 2021-08-13  232  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/[email protected]

Attachment: .config.gz
Description: application/gzip

_______________________________________________
kbuild mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to