tree: https://github.com/plbossart/sound fix/soundwire-interrupt-hardening head: d5727490522ccf031c969be6dc1c5f58545a216d commit: d5727490522ccf031c969be6dc1c5f58545a216d [12/12] soundwire: cadence_master: add dev_dbg traces for invalid interrupts config: x86_64-randconfig-a002-20200103 (attached as .config) compiler: gcc-7 (Debian 7.5.0-3) 7.5.0 reproduce: git checkout d5727490522ccf031c969be6dc1c5f58545a216d # save the attached .config to linux build tree make ARCH=x86_64 If you fix the issue, kindly add following tag Reported-by: kbuild test robot All warnings (new ones prefixed by >>): In file included from drivers//soundwire/cadence_master.c:10:0: drivers//soundwire/cadence_master.c: In function 'sdw_cdns_irq': >> drivers//soundwire/cadence_master.c:773:10: warning: format '%s' expects a matching 'char *' argument [-Wformat=] "%s: Invalid interrupt, status 0\n"); ^ include/linux/device.h:1691:22: note: in definition of macro 'dev_fmt' #define dev_fmt(fmt) fmt ^~~ >> drivers//soundwire/cadence_master.c:772:4: note: in expansion of macro 'dev_dbg_ratelimited' dev_dbg_ratelimited(cdns->dev, ^~~~~~~~~~~~~~~~~~~ vim +/dev_dbg_ratelimited +772 drivers//soundwire/cadence_master.c 740 741 /** 742 * sdw_cdns_irq() - Cadence interrupt handler 743 * @irq: irq number 744 * @dev_id: irq context 745 */ 746 irqreturn_t sdw_cdns_irq(int irq, void *dev_id) 747 { 748 struct sdw_cdns *cdns = dev_id; 749 u32 int_status; 750 int ret = IRQ_HANDLED; 751 752 /* Check if the link is up */ 753 if (!cdns->link_up) 754 return IRQ_NONE; 755 756 int_status = cdns_readl(cdns, CDNS_MCP_INTSTAT); 757 758 /* check for reserved values read as zero */ 759 if (int_status & CDNS_MCP_INT_RESERVED) { 760 dev_dbg_ratelimited(cdns->dev, 761 "%s: Invalid interrupt status bits %x\n", 762 __func__, int_status); 763 return IRQ_NONE; 764 } 765 766 if (!(int_status & CDNS_MCP_INT_IRQ)) { 767 if (int_status) 768 dev_dbg_ratelimited(cdns->dev, 769 "%s: Invalid interrupt cascade bit, status %x\n", 770 __func__, int_status); 771 else > 772 dev_dbg_ratelimited(cdns->dev, > 773 "%s: Invalid interrupt, status 0\n"); 774 return IRQ_NONE; 775 } 776 777 if (int_status & CDNS_MCP_INT_RX_WL) { 778 cdns_read_response(cdns); 779 780 if (cdns->defer) { 781 cdns_fill_msg_resp(cdns, cdns->defer->msg, 782 cdns->defer->length, 0); 783 complete(&cdns->defer->complete); 784 cdns->defer = NULL; 785 } else { 786 complete(&cdns->tx_complete); 787 } 788 } 789 790 if (int_status & CDNS_MCP_INT_PARITY) { 791 /* Parity error detected by Master */ 792 dev_err_ratelimited(cdns->dev, "Parity error\n"); 793 } 794 795 if (int_status & CDNS_MCP_INT_CTRL_CLASH) { 796 /* Slave is driving bit slot during control word */ 797 dev_err_ratelimited(cdns->dev, "Bus clash for control word\n"); 798 } 799 800 if (int_status & CDNS_MCP_INT_DATA_CLASH) { 801 /* 802 * Multiple slaves trying to drive bit slot, or issue with 803 * ownership of data bits or Slave gone bonkers 804 */ 805 dev_err_ratelimited(cdns->dev, "Bus clash for data word\n"); 806 } 807 808 if (int_status & CDNS_MCP_INT_SLAVE_MASK) { 809 /* Mask the Slave interrupt and wake thread */ 810 cdns_updatel(cdns, CDNS_MCP_INTMASK, 811 CDNS_MCP_INT_SLAVE_MASK, 0); 812 813 int_status &= ~CDNS_MCP_INT_SLAVE_MASK; 814 schedule_work(&cdns->work); 815 } 816 817 cdns_writel(cdns, CDNS_MCP_INTSTAT, int_status); 818 return ret; 819 } 820 EXPORT_SYMBOL(sdw_cdns_irq); 821 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org Intel Corporation