tree: https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git devel head: f55cf377e77b490e62c79f252de7820850cf502e commit: 1d652e61916b0e344ebce141574dd6de5bedbbfc [20/30] mxser: use timeout from uart_port config: powerpc-allmodconfig compiler: powerpc-linux-gcc (GCC) 12.1.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git/commit/?id=1d652e61916b0e344ebce141574dd6de5bedbbfc git remote add jirislaby https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git git fetch --no-tags jirislaby devel git checkout 1d652e61916b0e344ebce141574dd6de5bedbbfc # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=powerpc SHELL=/bin/bash M=drivers/tty If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot Note: the jirislaby/devel HEAD f55cf377e77b490e62c79f252de7820850cf502e builds fine. It only hurts bisectability. All errors (new ones prefixed by >>): drivers/tty/mxser.c: In function 'mxser_set_baud': >> drivers/tty/mxser.c:523:14: error: 'struct uart_port' has no member named 'timeout' 523 | uport->timeout = timeout + HZ / 50; /* Add .02 seconds of slop */ | ^~ drivers/tty/mxser.c: In function 'mxser_wait_until_sent': drivers/tty/mxser.c:1455:27: error: 'struct uart_port' has no member named 'timeout' 1455 | char_time = (uport->timeout - HZ / 50) / info->xmit_fifo_size; | ^~ drivers/tty/mxser.c:1473:44: error: 'struct uart_port' has no member named 'timeout' 1473 | if (!timeout || timeout > 2 * uport->timeout) | ^~ drivers/tty/mxser.c:1474:36: error: 'struct uart_port' has no member named 'timeout' 1474 | timeout = 2 * uport->timeout; | ^~ vim +523 drivers/tty/mxser.c 492 493 static int mxser_set_baud(struct mxser_port *info, struct ktermios *termios) 494 { 495 struct uart_port *uport = &info->uport; 496 unsigned int quot = 0, baud; 497 unsigned char cval; 498 speed_t newspd = tty_termios_baud_rate(termios); 499 u64 timeout; 500 501 if (newspd > info->board->max_baud) 502 return -1; 503 504 if (newspd == 134) { 505 quot = 2 * MXSER_BAUD_BASE / 269; 506 tty_termios_encode_baud_rate(termios, 134, 134); 507 } else if (newspd) { 508 quot = MXSER_BAUD_BASE / newspd; 509 if (quot == 0) 510 quot = 1; 511 baud = MXSER_BAUD_BASE / quot; 512 tty_termios_encode_baud_rate(termios, baud, baud); 513 } else { 514 quot = 0; 515 } 516 517 /* 518 * worst case (128 * 1000 * 10 * 18432) needs 35 bits, so divide in the 519 * u64 domain 520 */ 521 timeout = (u64)info->xmit_fifo_size * HZ * 10 * quot; 522 do_div(timeout, MXSER_BAUD_BASE); > 523 uport->timeout = timeout + HZ / 50; /* Add .02 seconds of slop */ 524 525 if (quot) { 526 info->MCR |= UART_MCR_DTR; 527 outb(info->MCR, uport->iobase + UART_MCR); 528 } else { 529 info->MCR &= ~UART_MCR_DTR; 530 outb(info->MCR, uport->iobase + UART_MCR); 531 return 0; 532 } 533 534 cval = inb(uport->iobase + UART_LCR); 535 536 outb(cval | UART_LCR_DLAB, uport->iobase + UART_LCR); /* set DLAB */ 537 538 outb(quot & 0xff, uport->iobase + UART_DLL); /* LS of divisor */ 539 outb(quot >> 8, uport->iobase + UART_DLM); /* MS of divisor */ 540 outb(cval, uport->iobase + UART_LCR); /* reset DLAB */ 541 542 if ((termios->c_cflag & CBAUD) == BOTHER) { 543 quot = MXSER_BAUD_BASE % newspd; 544 quot *= 8; 545 if (quot % newspd > newspd / 2) { 546 quot /= newspd; 547 quot++; 548 } else 549 quot /= newspd; 550 551 mxser_set_must_enum_value(uport->iobase, quot); 552 } else { 553 mxser_set_must_enum_value(uport->iobase, 0); 554 } 555 556 return 0; 557 } 558 -- 0-DAY CI Kernel Test Service https://01.org/lkp