/linux-master/drivers/gpu/drm/amd/display/dc/basics/ |
H A D | custom_float.c | 32 uint32_t *mantissa, 45 *mantissa = 0; 68 *mantissa = 0; 95 *mantissa = dc_fixpt_floor(mantiss); 102 uint32_t mantissa, 120 if (mantissa & ~mantissa_mask) { 122 mantissa = mantissa_mask; 135 if (mantissa & mask) 162 uint32_t mantissa; local 166 return build_custom_float(value, format, &negative, &mantissa, 29 build_custom_float(struct fixed31_32 value, const struct custom_float_format *format, bool *negative, uint32_t *mantissa, uint32_t *exponenta) argument 100 setup_custom_float(const struct custom_float_format *format, bool negative, uint32_t mantissa, uint32_t exponenta, uint32_t *result) argument [all...] |
/linux-master/drivers/iio/light/ |
H A D | max44009.c | 174 int mantissa; local 178 * The mantissa consists of the low nibble of the Lux High Byte 181 mantissa = ((hi & 0xf) << 4) | (lo & 0xf); 191 return exponent * mantissa; 301 int mantissa, exp; local 309 mantissa = integral * MAX44009_SCALE_DENOMINATOR; 310 mantissa /= MAX44009_SCALE_NUMERATOR; 313 mantissa += fractional / MAX44009_FRACT_MULT * 316 for (exp = 0; mantissa > 0xff; exp++) 317 mantissa >> 367 int mantissa, exponent; local [all...] |
H A D | opt3001.c | 171 u16 mantissa, int *val, int *val2) 175 lux = 10 * (mantissa << exponent); 227 u16 mantissa; local 340 mantissa = OPT3001_REG_MANTISSA(opt->result); 342 opt3001_to_iio_ret(opt, exponent, mantissa, val, val2); 479 u16 mantissa; local 496 mantissa = (((val * 1000) + (val2 / 1000)) / 10) >> exponent; 497 value = (exponent << 12) | mantissa; 502 opt->high_thresh_mantissa = mantissa; 507 opt->low_thresh_mantissa = mantissa; 170 opt3001_to_iio_ret(struct opt3001 *opt, u8 exponent, u16 mantissa, int *val, int *val2) argument [all...] |
H A D | opt4001.c | 148 static u8 opt4001_calculate_crc(u8 exp, u32 mantissa, u8 count) argument 152 crc = (hweight32(mantissa) + hweight32(exp) + hweight32(count)) % 2; 153 crc |= ((hweight32(mantissa & 0xAAAAA) + hweight32(exp & 0xA) 155 crc |= ((hweight32(mantissa & 0x88888) + hweight32(exp & 0x8) 157 crc |= (hweight32(mantissa & 0x80808) % 2) << 3;
|
/linux-master/drivers/hwmon/pmbus/ |
H A D | bpa-rs600.c | 44 * mantissa as unsigned. Deal with this here to allow the PMBus core 49 int ret, exponent, mantissa; local 57 mantissa = ret & 0x7ff; 60 mantissa >>= 1; 62 ret = (exponent << 11) | mantissa;
|
H A D | zl6100.c | 63 s32 mantissa; local 67 mantissa = ((s16)((l & 0x7ff) << 5)) >> 5; 69 val = mantissa; 87 s16 exponent = 0, mantissa; local 99 /* Reduce large mantissa until it fits into 10 bit */ 104 /* Increase small mantissa to improve precision */ 110 /* Convert mantissa from milli-units to units */ 111 mantissa = DIV_ROUND_CLOSEST(val, 1000); 114 if (mantissa > 0x3ff) 115 mantissa [all...] |
H A D | xdpe12284.c | 29 s32 mantissa; local 41 mantissa = ((s16)((ret & GENMASK(10, 0)) << 5)) >> 5; 42 val = mantissa * 1000L;
|
H A D | mp5990.c | 59 s32 mantissa; local 72 mantissa = ((s16)((ret & 0x7ff) << 5)) >> 5; 73 ret = mantissa;
|
H A D | mp2856.c | 79 s16 exponent = 0, mantissa; local 90 /* Reduce large mantissa until it fits into 10 bit */ 95 /* Increase small mantissa to improve precision */ 101 /* Convert mantissa from milli-units to units */ 102 mantissa = clamp_val(DIV_ROUND_CLOSEST_ULL(val, 1000), 0, 0x3ff); 106 mantissa = -mantissa; 108 /* Convert to 5 bit exponent, 11 bit mantissa */ 109 return (mantissa & 0x7ff) | ((exponent << 11) & 0xf800);
|
/linux-master/arch/m68k/fpsp040/ |
H A D | sgetem.S | 10 | The entry point sGETMAN extracts the mantissa of the 11 | input argument. The mantissa is converted to an 73 | For normalized numbers, leave the mantissa alone, simply load 89 | For denormalized numbers, shift the mantissa until the j-bit = 1, 96 bsr shft |shift mantissa bits till msbit is set 104 | Shifts the mantissa bits until msbit is set. 106 | ms mantissa part in d0 107 | ls mantissa part in d1
|
H A D | round.S | 154 tstl LOCAL_LO(%a0) |test lower mantissa 163 movel LOCAL_LO(%a0),%d2 |get lower mantissa for s-bit test 195 bccs scc_clr |no mantissa overflow 272 | is done by shifting the mantissa left while decrementing the 276 | bit of the mantissa (msb in d1). 279 | bit of the mantissa (msb in d1) unless this would mean the exponent 281 | exponent (d0) is set to 0 and the mantissa (d1 & d2) is not 289 | Distance to first 1 bit in mantissa = X 295 | shift mantissa by Y 299 | FP_SCR1 = exponent, ms mantissa par [all...] |
H A D | x_store.S | 140 beqs get_mant |if positive, go process mantissa 143 bras get_mant |go process mantissa 154 movel LOCAL_HI(%a1),%d1 |get ms mantissa 158 movel LOCAL_HI(%a1),%d1 |get ms mantissa 162 movel LOCAL_LO(%a1),%d1 |get ls mantissa 213 bras get_sman |get mantissa 222 movel LOCAL_HI(%a1),%d1 |get ms mantissa
|
H A D | fpsp.h | 132 .set WBTEMP_HI,WBTEMP+4 | wbtemp mantissa [63:32] (4 bytes) 133 .set WBTEMP_LO,WBTEMP+8 | wbtemp mantissa [31:00] (4 bytes) 165 .set wbtemp66_bit,2 | wbtemp mantissa bit #66 166 .set wbtemp1_bit,1 | wbtemp mantissa bit #1 167 .set wbtemp0_bit,0 | wbtemp mantissa bit #0 201 .set FPTEMP_HI,FPTEMP+4 | fptemp mantissa [63:32] (4 bytes) 202 .set FPTEMP_LO,FPTEMP+8 | fptemp mantissa [31:00] (4 bytes) 208 .set ETEMP_HI,ETEMP+4 | etemp mantissa [63:32] (4 bytes) 209 .set ETEMP_LO,ETEMP+8 | etemp mantissa [31:00] (4 bytes) 302 .set signan_bit,6 | signalling nan bit in mantissa [all...] |
H A D | decbin.S | 26 | for the mantissa which is to be interpreted as 17 integer 30 | A2. Convert the bcd mantissa to binary by successive 32 | The mantissa digits will be converted with the decimal point 41 | mantissa the equivalent of forcing in the bcd value: 56 | A5. Form the final binary number by scaling the mantissa by 58 | mantissa in FP0 by the factor in FP1 if the adjusted 171 | Calculate mantissa: 172 | 1. Calculate absolute value of mantissa in fp0 by mul and add. 173 | 2. Correct for mantissa sign. 186 | (*) fp0: mantissa accumulato [all...] |
H A D | scale.S | 164 | mantissa right until a zero exponent exists. 177 roxrl #1,%d2 |mantissa to the right 182 blts fix_loop |d0 is zero or the mantissa 297 | by first shifting the bits in the mantissa until it is normalized,
|
H A D | get_op.S | 286 btstb #sign_bit,ETEMP_EX(%a6) |grab sign bit of mantissa 503 tstl ETEMP_HI(%a6) |check ms mantissa 505 tstl ETEMP_LO(%a6) |check ls mantissa 555 tstl ETEMP_HI(%a6) |check ms mantissa 557 tstl ETEMP_LO(%a6) |check ls mantissa
|
/linux-master/drivers/hid/amd-sfh-hid/sfh1_1/ |
H A D | amd_sfh_desc.c | 137 int fraction, shift, mantissa, sign, exp, zeropre; local 139 mantissa = flt32_val & GENMASK(22, 0); 143 if (!exp && !mantissa) 155 zeropre = (((BIT(23) + mantissa) * 100) >> 23) >> exp; 165 flt32_val = BIT(exp) + (mantissa << shift); 168 flt32_val = BIT(exp) + (mantissa >> shift); 171 fraction = (shift == 0) ? 0 : mantissa & GENMASK(shift - 1, 0);
|
/linux-master/drivers/usb/serial/ |
H A D | pl2303.c | 612 unsigned int baseline, mantissa, exponent; local 616 * baudrate = 12M * 32 / (mantissa * 4^exponent) 618 * mantissa = buf[8:0] 622 mantissa = baseline / baud; 623 if (mantissa == 0) 624 mantissa = 1; /* Avoid dividing by zero if baud > 32*12M. */ 626 while (mantissa >= 512) { 628 mantissa >>= 2; /* divide by 4 */ 631 /* Exponent is maxed. Trim mantissa and leave. */ 632 mantissa 651 unsigned int baseline, mantissa, exponent; local [all...] |
/linux-master/sound/isa/gus/ |
H A D | gus_volume.c | 151 unsigned int mantissa, f1, f2; 165 mantissa = sensitivity % 8192; 172 bend = (int) ((((f2 - f1) * mantissa) >> 13) + f1);
|
/linux-master/drivers/iio/chemical/ |
H A D | sps30.c | 42 int mantissa = val & GENMASK(22, 0); local 48 if (!exp && !mantissa) 54 return ((((1 << 23) + mantissa) * 100) >> 23) >> (-exp); 59 val = (1 << exp) + (mantissa >> shift); 63 fraction = mantissa & GENMASK(shift - 1, 0);
|
H A D | scd30_core.c | 92 mantissa = float32 & GENMASK(22, 0), local 97 if (!exp && !mantissa) 104 return sign * ((((BIT(23) + mantissa) * 100) >> 23) >> exp); 109 float32 = BIT(exp) + (mantissa >> shift); 110 fraction = mantissa & GENMASK(shift - 1, 0);
|
/linux-master/arch/m68k/math-emu/ |
H A D | fp_util.S | 108 move.l %d0,(%a0)+ | set mantissa 131 lsl.l #8,%d0 | shift mantissa 168 lsl.l #8,%d0 | shift high mantissa 673 move.l (%a0),%d0 | low lword of mantissa 707 | round (the mantissa, that is) towards infinity 712 | Yow! we have managed to overflow the mantissa. Since this 866 move.l (%a0)+,%d0 | get high lword of mantissa 898 | round (the mantissa, that is) towards infinity 902 | is now zero. We will set the mantissa to reflect this, and 1026 move.l (%a0)+,%d0 | get high lword of mantissa [all...] |
/linux-master/drivers/isdn/mISDN/ |
H A D | dsp_audio.c | 124 int sign, exponent, mantissa; local 135 mantissa = (sample >> (exponent + 3)) & 0x0F; 136 ulawbyte = ~(sign | (exponent << 4) | mantissa);
|
/linux-master/drivers/net/wireless/mediatek/mt76/mt76x0/ |
H A D | phy.c | 669 u32 mantissa = val << 4; local 673 while (mantissa < BIT(15)) { 674 mantissa <<= 1; 678 while (mantissa > 0xffff) { 679 mantissa >>= 1; 685 if (mantissa <= 47104) 686 data = mantissa + (mantissa >> 3) + (mantissa >> 4) - 38400; 688 data = mantissa [all...] |
/linux-master/drivers/clk/ti/ |
H A D | dpll3xxx.c | 305 u32 v, ctrl, mod_freq_divider, exponent, mantissa; local 326 mantissa = mod_freq_divider; 327 while ((mantissa > 127) && (exponent < 7)) { 329 mantissa /= 2; 331 if (mantissa > 127) 332 mantissa = 127; 336 v |= mantissa << __ffs(dd->ssc_modfreq_mant_mask);
|