/kernel/linux/linux-5.10/lib/mpi/ |
H A D | mpi-div.c | 17 void mpi_tdiv_qr(MPI quot, MPI rem, MPI num, MPI den); 18 void mpi_fdiv_qr(MPI quot, MPI rem, MPI dividend, MPI divisor); 43 void mpi_fdiv_q(MPI quot, MPI dividend, MPI divisor) in mpi_fdiv_q() argument 45 MPI tmp = mpi_alloc(mpi_get_nlimbs(quot)); in mpi_fdiv_q() 46 mpi_fdiv_qr(quot, tmp, dividend, divisor); in mpi_fdiv_q() 50 void mpi_fdiv_qr(MPI quot, MPI rem, MPI dividend, MPI divisor) in mpi_fdiv_qr() argument 55 if (quot == divisor || rem == divisor) { in mpi_fdiv_qr() 60 mpi_tdiv_qr(quot, rem, dividend, divisor); in mpi_fdiv_qr() 63 mpi_sub_ui(quot, quot, in mpi_fdiv_qr() 83 mpi_tdiv_qr(MPI quot, MPI rem, MPI num, MPI den) mpi_tdiv_qr() argument [all...] |
/kernel/linux/linux-6.6/lib/crypto/mpi/ |
H A D | mpi-div.c | 17 void mpi_tdiv_qr(MPI quot, MPI rem, MPI num, MPI den); 18 void mpi_fdiv_qr(MPI quot, MPI rem, MPI dividend, MPI divisor); 43 void mpi_fdiv_q(MPI quot, MPI dividend, MPI divisor) in mpi_fdiv_q() argument 45 MPI tmp = mpi_alloc(mpi_get_nlimbs(quot)); in mpi_fdiv_q() 46 mpi_fdiv_qr(quot, tmp, dividend, divisor); in mpi_fdiv_q() 50 void mpi_fdiv_qr(MPI quot, MPI rem, MPI dividend, MPI divisor) in mpi_fdiv_qr() argument 55 if (quot == divisor || rem == divisor) { in mpi_fdiv_qr() 60 mpi_tdiv_qr(quot, rem, dividend, divisor); in mpi_fdiv_qr() 63 mpi_sub_ui(quot, quot, in mpi_fdiv_qr() 83 mpi_tdiv_qr(MPI quot, MPI rem, MPI num, MPI den) mpi_tdiv_qr() argument [all...] |
/kernel/linux/linux-5.10/lib/math/ |
H A D | div64.c | 105 u64 quot; in div64_u64_rem() local 109 quot = div_u64_rem(dividend, divisor, &rem32); in div64_u64_rem() 113 quot = div_u64(dividend >> n, divisor >> n); in div64_u64_rem() 115 if (quot != 0) in div64_u64_rem() 116 quot--; in div64_u64_rem() 118 *remainder = dividend - quot * divisor; in div64_u64_rem() 120 quot++; in div64_u64_rem() 125 return quot; in div64_u64_rem() 145 u64 quot; in div64_u64() local 148 quot in div64_u64() 172 s64 quot, t; div64_s64() local [all...] |
/kernel/linux/linux-6.6/lib/math/ |
H A D | div64.c | 101 u64 quot; in div64_u64_rem() local 105 quot = div_u64_rem(dividend, divisor, &rem32); in div64_u64_rem() 109 quot = div_u64(dividend >> n, divisor >> n); in div64_u64_rem() 111 if (quot != 0) in div64_u64_rem() 112 quot--; in div64_u64_rem() 114 *remainder = dividend - quot * divisor; in div64_u64_rem() 116 quot++; in div64_u64_rem() 121 return quot; in div64_u64_rem() 141 u64 quot; in div64_u64() local 144 quot in div64_u64() 163 s64 quot, t; div64_s64() local [all...] |
/kernel/linux/linux-5.10/drivers/usb/serial/ |
H A D | ark3116.c | 65 int quot; /* baudrate divisor */ member 164 priv->quot = calc_divisor(9600); in ark3116_port_probe() 165 ark3116_write_reg(serial, UART_DLL, priv->quot & 0xff); in ark3116_port_probe() 166 ark3116_write_reg(serial, UART_DLM, (priv->quot>>8) & 0xff); in ark3116_port_probe() 201 int quot; in ark3116_set_termios() local 238 quot = calc_divisor(9600); in ark3116_set_termios() 243 quot = calc_divisor(bps); in ark3116_set_termios() 247 quot = calc_divisor(bps); in ark3116_set_termios() 251 quot = calc_divisor(bps); in ark3116_set_termios() 261 dev_dbg(&port->dev, "%s - setting hcr:0x%02x,lcr:0x%02x,quot in ark3116_set_termios() [all...] |
/kernel/linux/linux-6.6/drivers/usb/serial/ |
H A D | ark3116.c | 65 int quot; /* baudrate divisor */ member 164 priv->quot = calc_divisor(9600); in ark3116_port_probe() 165 ark3116_write_reg(serial, UART_DLL, priv->quot & 0xff); in ark3116_port_probe() 166 ark3116_write_reg(serial, UART_DLM, (priv->quot>>8) & 0xff); in ark3116_port_probe() 199 int quot; in ark3116_set_termios() local 222 quot = calc_divisor(9600); in ark3116_set_termios() 227 quot = calc_divisor(bps); in ark3116_set_termios() 231 quot = calc_divisor(bps); in ark3116_set_termios() 235 quot = calc_divisor(bps); in ark3116_set_termios() 245 dev_dbg(&port->dev, "%s - setting hcr:0x%02x,lcr:0x%02x,quot in ark3116_set_termios() [all...] |
/kernel/linux/linux-5.10/tools/perf/util/ |
H A D | tsc.c | 18 u64 t, quot, rem; in perf_time_to_tsc() local 21 quot = t / tc->time_mult; in perf_time_to_tsc() 23 return (quot << tc->time_shift) + in perf_time_to_tsc() 29 u64 quot, rem; in tsc_to_perf_time() local 35 quot = cyc >> tc->time_shift; in tsc_to_perf_time() 37 return tc->time_zero + quot * tc->time_mult + in tsc_to_perf_time()
|
/kernel/linux/linux-6.6/tools/perf/util/ |
H A D | tsc.c | 20 u64 t, quot, rem; in perf_time_to_tsc() local 23 quot = t / tc->time_mult; in perf_time_to_tsc() 25 return (quot << tc->time_shift) + in perf_time_to_tsc() 31 u64 quot, rem; in tsc_to_perf_time() local 37 quot = cyc >> tc->time_shift; in tsc_to_perf_time() 39 return tc->time_zero + quot * tc->time_mult + in tsc_to_perf_time()
|
/kernel/linux/linux-5.10/drivers/tty/serial/8250/ |
H A D | 8250_dwlib.c | 53 * quot = div(I) = clk / (16 * baud) 63 unsigned int quot, rem, base_baud = baud * 16; in dw8250_get_divisor() local 66 quot = p->uartclk / base_baud; in dw8250_get_divisor() 70 return quot; in dw8250_get_divisor() 74 unsigned int quot, unsigned int quot_frac) in dw8250_set_divisor() 77 serial8250_do_set_divisor(p, baud, quot, quot_frac); in dw8250_set_divisor() 73 dw8250_set_divisor(struct uart_port *p, unsigned int baud, unsigned int quot, unsigned int quot_frac) dw8250_set_divisor() argument
|
/kernel/linux/linux-5.10/tools/perf/arch/x86/tests/ |
H A D | rdpmc.c | 66 u64 quot, rem; in mmap_read_self() local 68 quot = (cyc >> time_shift); in mmap_read_self() 70 delta = time_offset + quot * time_mult + in mmap_read_self() 77 quot = count / running; in mmap_read_self() 79 count = quot * enabled + (rem * enabled) / running; in mmap_read_self()
|
/kernel/linux/linux-6.6/tools/include/linux/ |
H A D | math64.h | 66 u64 quot, rem; in mul_u64_u64_div64() local 68 quot = a / c; in mul_u64_u64_div64() 71 return quot * b + (rem * b) / c; in mul_u64_u64_div64()
|
/kernel/linux/linux-6.6/drivers/tty/serial/ |
H A D | serial_txx9.c | 193 sio_quot_set(struct uart_port *up, int quot) in sio_quot_set() argument 195 quot >>= 1; in sio_quot_set() 196 if (quot < 256) in sio_quot_set() 197 sio_out(up, TXX9_SIBGR, quot | TXX9_SIBGR_BCLK_T0); in sio_quot_set() 198 else if (quot < (256 << 2)) in sio_quot_set() 199 sio_out(up, TXX9_SIBGR, (quot >> 2) | TXX9_SIBGR_BCLK_T2); in sio_quot_set() 200 else if (quot < (256 << 4)) in sio_quot_set() 201 sio_out(up, TXX9_SIBGR, (quot >> 4) | TXX9_SIBGR_BCLK_T4); in sio_quot_set() 202 else if (quot < (256 << 6)) in sio_quot_set() 203 sio_out(up, TXX9_SIBGR, (quot >> in sio_quot_set() 578 unsigned int baud, quot; serial_txx9_set_termios() local [all...] |
H A D | sunsu.c | 482 unsigned int iflag, unsigned int quot); 487 int quot, new_baud; in sunsu_change_mouse_baud() local 492 quot = up->port.uartclk / (16 * new_baud); in sunsu_change_mouse_baud() 494 sunsu_change_speed(&up->port, up->cflag, 0, quot); in sunsu_change_mouse_baud() 771 unsigned int iflag, unsigned int quot) in sunsu_change_speed() 808 if ((quot & 0xff) == 0 && up->port.type == PORT_16C950 && in sunsu_change_speed() 810 quot ++; in sunsu_change_speed() 813 if ((up->port.uartclk / quot) < (2400 * 16)) in sunsu_change_speed() 834 uart_update_timeout(port, cflag, (port->uartclk / (16 * quot))); in sunsu_change_speed() 878 serial_outp(up, UART_DLL, quot in sunsu_change_speed() 770 sunsu_change_speed(struct uart_port *port, unsigned int cflag, unsigned int iflag, unsigned int quot) sunsu_change_speed() argument 901 unsigned int baud, quot; sunsu_set_termios() local 1188 int quot, baud; sunsu_kbd_ms_init() local [all...] |
/kernel/linux/linux-5.10/drivers/tty/ |
H A D | amiserial.c | 96 int quot; member 612 int quot = 0, baud_base, baud; in change_speed() local 643 quot = info->custom_divisor; in change_speed() 647 quot = (2*baud_base / 269); in change_speed() 649 quot = baud_base / baud; in change_speed() 652 if (!quot && old_termios) { in change_speed() 661 quot = info->custom_divisor; in change_speed() 665 quot = (2*baud_base / 269); in change_speed() 667 quot = baud_base / baud; in change_speed() 671 if (!quot) in change_speed() [all...] |
/kernel/linux/linux-5.10/drivers/tty/serial/ |
H A D | sunsu.c | 486 unsigned int iflag, unsigned int quot); 491 int quot, new_baud; in sunsu_change_mouse_baud() local 496 quot = up->port.uartclk / (16 * new_baud); in sunsu_change_mouse_baud() 498 sunsu_change_speed(&up->port, up->cflag, 0, quot); in sunsu_change_mouse_baud() 775 unsigned int iflag, unsigned int quot) in sunsu_change_speed() 814 if ((quot & 0xff) == 0 && up->port.type == PORT_16C950 && in sunsu_change_speed() 816 quot ++; in sunsu_change_speed() 819 if ((up->port.uartclk / quot) < (2400 * 16)) in sunsu_change_speed() 840 uart_update_timeout(port, cflag, (port->uartclk / (16 * quot))); in sunsu_change_speed() 884 serial_outp(up, UART_DLL, quot in sunsu_change_speed() 774 sunsu_change_speed(struct uart_port *port, unsigned int cflag, unsigned int iflag, unsigned int quot) sunsu_change_speed() argument 907 unsigned int baud, quot; sunsu_set_termios() local 1194 int quot, baud; sunsu_kbd_ms_init() local [all...] |
H A D | apbuart.c | 237 unsigned int baud, quot; in apbuart_set_termios() local 245 quot = (uart_get_divisor(port, baud)) * 2; in apbuart_set_termios() 278 quot -= 1; in apbuart_set_termios() 279 UART_PUT_SCAL(port, quot); in apbuart_set_termios() 456 unsigned int quot, status; in apbuart_console_get_options() local 468 quot = UART_GET_SCAL(port) / 8; in apbuart_console_get_options() 469 *baud = port->uartclk / (16 * (quot + 1)); in apbuart_console_get_options()
|
/kernel/linux/linux-6.6/drivers/tty/ |
H A D | amiserial.c | 81 int quot; member 572 int quot = 0, baud_base, baud; in change_speed() local 601 quot = info->custom_divisor; in change_speed() 605 quot = (2*baud_base / 269); in change_speed() 607 quot = baud_base / baud; in change_speed() 610 if (!quot && old_termios) { in change_speed() 619 quot = info->custom_divisor; in change_speed() 623 quot = (2*baud_base / 269); in change_speed() 625 quot = baud_base / baud; in change_speed() 629 if (!quot) in change_speed() [all...] |
/kernel/linux/linux-5.10/arch/powerpc/platforms/embedded6xx/ |
H A D | ls_uart.c | 61 unsigned int quot = AVR_QUOT(avr_clock); in avr_uart_configure() local 75 out_8(avr_addr + UART_DLL, quot & 0xff); /* LS of divisor */ in avr_uart_configure() 76 out_8(avr_addr + UART_DLM, quot >> 8); /* MS of divisor */ in avr_uart_configure()
|
/kernel/linux/linux-5.10/arch/x86/boot/ |
H A D | early_serial_console.c | 105 unsigned int quot; in probe_baud() local 112 quot = (dlh << 8) | dll; in probe_baud() 114 return BASE_BAUD / quot; in probe_baud()
|
/kernel/linux/linux-6.6/arch/powerpc/platforms/embedded6xx/ |
H A D | ls_uart.c | 62 unsigned int quot = AVR_QUOT(avr_clock); in avr_uart_configure() local 76 out_8(avr_addr + UART_DLL, quot & 0xff); /* LS of divisor */ in avr_uart_configure() 77 out_8(avr_addr + UART_DLM, quot >> 8); /* MS of divisor */ in avr_uart_configure()
|
/kernel/linux/linux-6.6/arch/x86/boot/ |
H A D | early_serial_console.c | 105 unsigned int quot; in probe_baud() local 112 quot = (dlh << 8) | dll; in probe_baud() 114 return BASE_BAUD / quot; in probe_baud()
|
/kernel/linux/linux-5.10/drivers/accessibility/speakup/ |
H A D | serialio.c | 50 int baud = 9600, quot = 0; in spk_serial_init() local 63 quot = ser->baud_base / baud; in spk_serial_init() 90 outb(quot & 0xff, ser->port + UART_DLL); /* LS of divisor */ in spk_serial_init() 91 outb(quot >> 8, ser->port + UART_DLM); /* MS of divisor */ in spk_serial_init()
|
/kernel/linux/linux-5.10/drivers/phy/intel/ |
H A D | phy-intel-lgm-emmc.c | 58 int ret, quot; in intel_emmc_phy_power() local 76 quot = DIV_ROUND_CLOSEST(rate, 50000000); in intel_emmc_phy_power() 77 if (quot > FRQSEL_150M) in intel_emmc_phy_power() 79 freqsel = clamp_t(int, quot, FRQSEL_25M, FRQSEL_150M); in intel_emmc_phy_power()
|
/kernel/linux/linux-6.6/drivers/phy/intel/ |
H A D | phy-intel-lgm-emmc.c | 58 int ret, quot; in intel_emmc_phy_power() local 76 quot = DIV_ROUND_CLOSEST(rate, 50000000); in intel_emmc_phy_power() 77 if (quot > FRQSEL_150M) in intel_emmc_phy_power() 79 freqsel = clamp_t(int, quot, FRQSEL_25M, FRQSEL_150M); in intel_emmc_phy_power()
|
/kernel/linux/linux-6.6/drivers/tty/serial/8250/ |
H A D | 8250_dwlib.c | 68 * quot = div(I) = clk / (16 * baud) 78 unsigned int quot, rem, base_baud = baud * 16; in dw8250_get_divisor() local 81 quot = p->uartclk / base_baud; in dw8250_get_divisor() 85 return quot; in dw8250_get_divisor() 89 unsigned int quot, unsigned int quot_frac) in dw8250_set_divisor() 92 serial8250_do_set_divisor(p, baud, quot, quot_frac); in dw8250_set_divisor() 88 dw8250_set_divisor(struct uart_port *p, unsigned int baud, unsigned int quot, unsigned int quot_frac) dw8250_set_divisor() argument
|