tree: https://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic.git master head: f153efce6212224d2448cd6661626ace885c42c0 commit: 8312c0cad7923a82d27c305c3fda1e05014fdf40 [55/64] usb: musb: remove blackfin port config: sparc64-allyesconfig (attached as .config) compiler: sparc64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross git checkout 8312c0cad7923a82d27c305c3fda1e05014fdf40 # save the attached .config to linux build tree make.cross ARCH=sparc64 All errors (new ones prefixed by >>): drivers/usb/musb/musb_host.c: In function 'musb_rx_reinit': >> drivers/usb/musb/musb_host.c:577:10: error: 'struct musb' has no member named 'double_buffer_not_ok' if (musb->double_buffer_not_ok) ^~ drivers/usb/musb/musb_host.c: In function 'musb_ep_program': drivers/usb/musb/musb_host.c:807:12: error: 'struct musb' has no member named 'double_buffer_not_ok' if (musb->double_buffer_not_ok) { ^~ -- drivers/usb/musb/musb_gadget.c: In function 'musb_gadget_enable': >> drivers/usb/musb/musb_gadget.c:998:11: error: 'struct musb' has no member named 'double_buffer_not_ok' if (musb->double_buffer_not_ok) { ^~ drivers/usb/musb/musb_gadget.c:1041:11: error: 'struct musb' has no member named 'double_buffer_not_ok' if (musb->double_buffer_not_ok) ^~ vim +577 drivers/usb/musb/musb_host.c 550a7375f Felipe Balbi 2008-07-24 515 550a7375f Felipe Balbi 2008-07-24 516 /* we don't always need to reinit a given side of an endpoint... 550a7375f Felipe Balbi 2008-07-24 517 * when we do, use tx/rx reinit routine and then construct a new CSR 550a7375f Felipe Balbi 2008-07-24 518 * to address data toggle, NYET, and DMA or PIO. 550a7375f Felipe Balbi 2008-07-24 519 * 550a7375f Felipe Balbi 2008-07-24 520 * it's possible that driver bugs (especially for DMA) or aborting a 550a7375f Felipe Balbi 2008-07-24 521 * transfer might have left the endpoint busier than it should be. 550a7375f Felipe Balbi 2008-07-24 522 * the busy/not-empty tests are basically paranoia. 550a7375f Felipe Balbi 2008-07-24 523 */ 550a7375f Felipe Balbi 2008-07-24 524 static void 0cb74b3dc Hans de Goede 2015-03-20 525 musb_rx_reinit(struct musb *musb, struct musb_qh *qh, u8 epnum) 550a7375f Felipe Balbi 2008-07-24 526 { 0cb74b3dc Hans de Goede 2015-03-20 527 struct musb_hw_ep *ep = musb->endpoints + epnum; 550a7375f Felipe Balbi 2008-07-24 528 u16 csr; 550a7375f Felipe Balbi 2008-07-24 529 550a7375f Felipe Balbi 2008-07-24 530 /* NOTE: we know the "rx" fifo reinit never triggers for ep0. 550a7375f Felipe Balbi 2008-07-24 531 * That always uses tx_reinit since ep0 repurposes TX register 550a7375f Felipe Balbi 2008-07-24 532 * offsets; the initial SETUP packet is also a kind of OUT. 550a7375f Felipe Balbi 2008-07-24 533 */ 550a7375f Felipe Balbi 2008-07-24 534 550a7375f Felipe Balbi 2008-07-24 535 /* if programmed for Tx, put it in RX mode */ 550a7375f Felipe Balbi 2008-07-24 536 if (ep->is_shared_fifo) { 550a7375f Felipe Balbi 2008-07-24 537 csr = musb_readw(ep->regs, MUSB_TXCSR); 550a7375f Felipe Balbi 2008-07-24 538 if (csr & MUSB_TXCSR_MODE) { 550a7375f Felipe Balbi 2008-07-24 539 musb_h_tx_flush_fifo(ep); b6e434a54 Sergei Shtylyov 2009-03-26 540 csr = musb_readw(ep->regs, MUSB_TXCSR); 550a7375f Felipe Balbi 2008-07-24 541 musb_writew(ep->regs, MUSB_TXCSR, b6e434a54 Sergei Shtylyov 2009-03-26 542 csr | MUSB_TXCSR_FRCDATATOG); 550a7375f Felipe Balbi 2008-07-24 543 } b6e434a54 Sergei Shtylyov 2009-03-26 544 b6e434a54 Sergei Shtylyov 2009-03-26 545 /* b6e434a54 Sergei Shtylyov 2009-03-26 546 * Clear the MODE bit (and everything else) to enable Rx. b6e434a54 Sergei Shtylyov 2009-03-26 547 * NOTE: we mustn't clear the DMAMODE bit before DMAENAB. b6e434a54 Sergei Shtylyov 2009-03-26 548 */ b6e434a54 Sergei Shtylyov 2009-03-26 549 if (csr & MUSB_TXCSR_DMAMODE) b6e434a54 Sergei Shtylyov 2009-03-26 550 musb_writew(ep->regs, MUSB_TXCSR, MUSB_TXCSR_DMAMODE); 550a7375f Felipe Balbi 2008-07-24 551 musb_writew(ep->regs, MUSB_TXCSR, 0); 550a7375f Felipe Balbi 2008-07-24 552 550a7375f Felipe Balbi 2008-07-24 553 /* scrub all previous state, clearing toggle */ f3eec0cf7 Andrew Goodbody 2016-05-31 554 } 550a7375f Felipe Balbi 2008-07-24 555 csr = musb_readw(ep->regs, MUSB_RXCSR); 550a7375f Felipe Balbi 2008-07-24 556 if (csr & MUSB_RXCSR_RXPKTRDY) 550a7375f Felipe Balbi 2008-07-24 557 WARNING("rx%d, packet/%d ready?\n", ep->epnum, 550a7375f Felipe Balbi 2008-07-24 558 musb_readw(ep->regs, MUSB_RXCOUNT)); 550a7375f Felipe Balbi 2008-07-24 559 550a7375f Felipe Balbi 2008-07-24 560 musb_h_flush_rxfifo(ep, MUSB_RXCSR_CLRDATATOG); 550a7375f Felipe Balbi 2008-07-24 561 550a7375f Felipe Balbi 2008-07-24 562 /* target addr and (for multipoint) hub addr/port */ 550a7375f Felipe Balbi 2008-07-24 563 if (musb->is_multipoint) { 6cc2af6d5 Hans de Goede 2015-03-20 564 musb_write_rxfunaddr(musb, epnum, qh->addr_reg); 6cc2af6d5 Hans de Goede 2015-03-20 565 musb_write_rxhubaddr(musb, epnum, qh->h_addr_reg); 6cc2af6d5 Hans de Goede 2015-03-20 566 musb_write_rxhubport(musb, epnum, qh->h_port_reg); 550a7375f Felipe Balbi 2008-07-24 567 } else 550a7375f Felipe Balbi 2008-07-24 568 musb_writeb(musb->mregs, MUSB_FADDR, qh->addr_reg); 550a7375f Felipe Balbi 2008-07-24 569 550a7375f Felipe Balbi 2008-07-24 570 /* protocol/endpoint, interval/NAKlimit, i/o size */ 550a7375f Felipe Balbi 2008-07-24 571 musb_writeb(ep->regs, MUSB_RXTYPE, qh->type_reg); 550a7375f Felipe Balbi 2008-07-24 572 musb_writeb(ep->regs, MUSB_RXINTERVAL, qh->intv_reg); 550a7375f Felipe Balbi 2008-07-24 573 /* NOTE: bulk combining rewrites high bits of maxpacket */ 9f445cb29 Cliff Cai 2010-01-28 574 /* Set RXMAXP with the FIFO size of the endpoint 9f445cb29 Cliff Cai 2010-01-28 575 * to disable double buffer mode. 9f445cb29 Cliff Cai 2010-01-28 576 */ 066248185 Felipe Balbi 2011-01-21 @577 if (musb->double_buffer_not_ok) 9f445cb29 Cliff Cai 2010-01-28 578 musb_writew(ep->regs, MUSB_RXMAXP, ep->max_packet_sz_rx); 9f445cb29 Cliff Cai 2010-01-28 579 else a483d7068 Ajay Kumar Gupta 2009-04-03 580 musb_writew(ep->regs, MUSB_RXMAXP, a483d7068 Ajay Kumar Gupta 2009-04-03 581 qh->maxpacket | ((qh->hb_mult - 1) << 11)); 550a7375f Felipe Balbi 2008-07-24 582 550a7375f Felipe Balbi 2008-07-24 583 ep->rx_reinit = 0; 550a7375f Felipe Balbi 2008-07-24 584 } 550a7375f Felipe Balbi 2008-07-24 585 :::::: The code at line 577 was first introduced by commit :::::: 0662481855c389b75a0a54c32870cc90563d80a9 usb: musb: disable double buffering when it's broken :::::: TO: Felipe Balbi <balbi@xxxxxx> :::::: CC: Felipe Balbi <balbi@xxxxxx> --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
Attachment:
.config.gz
Description: application/gzip