Home
last modified time | relevance | path

Searched refs:csum (Results 1 – 25 of 132) sorted by relevance

123456

/drivers/infiniband/hw/qib/
Dqib_eeprom.c117 u8 csum = 0, len; in flash_csum() local
128 csum += *ip++; in flash_csum()
129 csum -= ifp->if_csum; in flash_csum()
130 csum = ~csum; in flash_csum()
132 ifp->if_csum = csum; in flash_csum()
134 return csum; in flash_csum()
150 u8 csum, *bguid; in qib_get_eeprom_info() local
203 csum = flash_csum(ifp, 0); in qib_get_eeprom_info()
204 if (csum != ifp->if_csum) { in qib_get_eeprom_info()
207 csum, ifp->if_csum); in qib_get_eeprom_info()
[all …]
/drivers/infiniband/hw/ipath/
Dipath_eeprom.c679 u8 csum = 0, len; in flash_csum() local
690 csum += *ip++; in flash_csum()
691 csum -= ifp->if_csum; in flash_csum()
692 csum = ~csum; in flash_csum()
694 ifp->if_csum = csum; in flash_csum()
696 return csum; in flash_csum()
712 u8 csum, *bguid; in ipath_get_eeprom_info() local
769 csum = flash_csum(ifp, 0); in ipath_get_eeprom_info()
770 if (csum != ifp->if_csum) { in ipath_get_eeprom_info()
772 "0x%x, not 0x%x\n", csum, ifp->if_csum); in ipath_get_eeprom_info()
[all …]
/drivers/input/touchscreen/
Delo.c64 unsigned char csum; member
78 elo->csum = 0xaa; in elo_process_data_10()
88 if (data != elo->csum) { in elo_process_data_10()
91 data, elo->csum); in elo_process_data_10()
119 elo->csum += data; in elo_process_data_10()
229 unsigned char csum = 0xaa + ELO10_LEAD_BYTE; in elo_command_10() local
242 csum += packet[i]; in elo_command_10()
247 if (serio_write(elo->serio, csum)) in elo_command_10()
/drivers/accessibility/braille/
Dbraille_console.c78 unsigned char data[1 + 1 + 2*WIDTH + 2 + 1], csum = 0, *c; in braille_write() local
96 csum ^= '>'; in braille_write()
104 csum ^= out; in braille_write()
112 if (csum <= 0x05) { in braille_write()
114 csum |= 0x40; in braille_write()
116 *c++ = csum; in braille_write()
/drivers/scsi/
Dsd_dif.c89 __u16 csum; in sd_dif_type1_verify() local
104 csum = fn(buf, bix->sector_size); in sd_dif_type1_verify()
106 if (sdt->guard_tag != csum) { in sd_dif_type1_verify()
110 be16_to_cpu(sdt->guard_tag), be16_to_cpu(csum)); in sd_dif_type1_verify()
214 __u16 csum; in sd_dif_type3_verify() local
221 csum = fn(buf, bix->sector_size); in sd_dif_type3_verify()
223 if (sdt->guard_tag != csum) { in sd_dif_type3_verify()
227 be16_to_cpu(sdt->guard_tag), be16_to_cpu(csum)); in sd_dif_type3_verify()
/drivers/net/ethernet/sgi/
Dioc3-eth.c511 uint32_t csum, ehsum; in ioc3_tcpudp_checksum() local
543 csum = hwsum + in ioc3_tcpudp_checksum()
556 csum += 0xffff ^ ehsum; in ioc3_tcpudp_checksum()
562 csum += 0xffff ^ (uint16_t) ((cp[1] << 8) | cp[0]); in ioc3_tcpudp_checksum()
563 csum += 0xffff ^ (uint16_t) ((cp[3] << 8) | cp[2]); in ioc3_tcpudp_checksum()
565 csum += 0xffff ^ (uint16_t) ((cp[0] << 8) | cp[1]); in ioc3_tcpudp_checksum()
566 csum += 0xffff ^ (uint16_t) ((cp[2] << 8) | cp[3]); in ioc3_tcpudp_checksum()
569 csum = (csum & 0xffff) + (csum >> 16); in ioc3_tcpudp_checksum()
570 csum = (csum & 0xffff) + (csum >> 16); in ioc3_tcpudp_checksum()
572 if (csum == 0xffff) in ioc3_tcpudp_checksum()
[all …]
/drivers/net/ethernet/stmicro/stmmac/
Dring_mode.c31 static unsigned int stmmac_jumbo_frm(void *p, struct sk_buff *skb, int csum) in stmmac_jumbo_frm() argument
53 priv->hw->desc->prepare_tx_desc(desc, 1, bmax, csum, in stmmac_jumbo_frm()
63 priv->hw->desc->prepare_tx_desc(desc, 0, len, csum, in stmmac_jumbo_frm()
73 priv->hw->desc->prepare_tx_desc(desc, 1, nopaged_len, csum, in stmmac_jumbo_frm()
Dchain_mode.c31 static unsigned int stmmac_jumbo_frm(void *p, struct sk_buff *skb, int csum) in stmmac_jumbo_frm() argument
51 priv->hw->desc->prepare_tx_desc(desc, 1, bmax, csum, STMMAC_CHAIN_MODE); in stmmac_jumbo_frm()
62 priv->hw->desc->prepare_tx_desc(desc, 0, bmax, csum, in stmmac_jumbo_frm()
73 priv->hw->desc->prepare_tx_desc(desc, 0, len, csum, in stmmac_jumbo_frm()
/drivers/mfd/
Dcros_ec.c31 int csum, i; in cros_ec_prepare_tx() local
38 csum = out[0] + out[1] + out[2]; in cros_ec_prepare_tx()
40 csum += out[EC_MSG_TX_HEADER_BYTES + i] = msg->out_buf[i]; in cros_ec_prepare_tx()
41 out[EC_MSG_TX_HEADER_BYTES + msg->out_len] = (uint8_t)(csum & 0xff); in cros_ec_prepare_tx()
/drivers/scsi/sym53c8xx_2/
Dsym_nvram.c515 u_short csum; in sym_read_Symbios_nvram() local
529 for (x = 6, csum = 0; x < len - 6; x++) in sym_read_Symbios_nvram()
530 csum += data[x]; in sym_read_Symbios_nvram()
531 if (csum != nvram->checksum) in sym_read_Symbios_nvram()
696 u_short csum; in sym_read_Tekram_nvram() local
719 for (x = 0, csum = 0; x < len - 1; x += 2) in sym_read_Tekram_nvram()
720 csum += data[x] + (data[x+1] << 8); in sym_read_Tekram_nvram()
721 if (csum != 0x1234) in sym_read_Tekram_nvram()
/drivers/video/
Dmetronomefb.c335 par->metromem_cmd->csum = cs; in metronome_display_cmd()
359 par->metromem_cmd->csum = cs; in metronome_powerup_cmd()
381 par->metromem_cmd->csum = 0xCC10; in metronome_config_cmd()
382 par->metromem_cmd->csum += calc_img_cksum(par->metromem_cmd->args, 4); in metronome_config_cmd()
408 par->metromem_cmd->csum = cs; in metronome_init_cmd()
453 u16 csum = 0; in metronomefb_dpy_update_page() local
460 csum += *(img + i); in metronomefb_dpy_update_page()
462 return csum; in metronomefb_dpy_update_page()
Dhdmi.c33 u8 csum = 0; in hdmi_infoframe_checksum() local
38 csum += ptr[i]; in hdmi_infoframe_checksum()
40 ptr[3] = 256 - csum; in hdmi_infoframe_checksum()
/drivers/net/usb/
Dax88179_178a.c727 u16 csum, delay = HZ / 10; in ax88179_check_eeprom() local
759 csum = eeprom[6] + eeprom[7] + eeprom[8] + eeprom[9]; in ax88179_check_eeprom()
760 csum = (csum >> 8) + (csum & 0xff); in ax88179_check_eeprom()
761 if ((csum + eeprom[10]) != 0xff) in ax88179_check_eeprom()
771 u16 csum = 0; in ax88179_check_efuse() local
780 csum = csum + efuse[i]; in ax88179_check_efuse()
782 while (csum > 255) in ax88179_check_efuse()
783 csum = (csum & 0x00FF) + ((csum >> 8) & 0x00FF); in ax88179_check_efuse()
785 if (csum != 0xFF) in ax88179_check_efuse()
/drivers/block/
Damiflop.c678 unsigned long csum = 0; in checksum() local
682 csum ^= *addr++; in checksum()
683 csum = ((csum>>1) & 0x55555555) ^ (csum & 0x55555555); in checksum()
685 return csum; in checksum()
723 unsigned long csum; in amiga_read() local
740 csum = checksum((ulong *)&hdr, in amiga_read()
751 if (hdr.hdrchk != csum) { in amiga_read()
752 printk(KERN_INFO "MFM_HEADER: %08lx,%08lx\n", hdr.hdrchk, csum); in amiga_read()
764 csum = checksum((ulong *)(unit[drive].trackbuf + hdr.sect*512), 512); in amiga_read()
766 if (hdr.datachk != csum) { in amiga_read()
[all …]
/drivers/net/ethernet/intel/e1000e/
Dmanage.c122 s32 ret_val, hdr_csum, csum; in e1000e_enable_tx_pkt_filtering() local
150 csum = e1000_calculate_checksum((u8 *)hdr, in e1000e_enable_tx_pkt_filtering()
156 if ((hdr_csum != csum) || (hdr->signature != E1000_IAMT_SIGNATURE)) { in e1000e_enable_tx_pkt_filtering()
/drivers/md/persistent-data/
Ddm-btree-spine.c30 h->csum = cpu_to_le32(dm_bm_checksum(&h->flags, in node_prepare_for_write()
56 if (csum_disk != h->csum) { in node_check()
58 le32_to_cpu(csum_disk), le32_to_cpu(h->csum)); in node_check()
Ddm-space-map-common.h41 __le32 csum; member
94 __le32 csum; member
Ddm-space-map-common.c29 mi_le->csum = cpu_to_le32(dm_bm_checksum(&mi_le->padding, in index_prepare_for_write()
50 if (csum_disk != mi_le->csum) { in index_check()
52 le32_to_cpu(csum_disk), le32_to_cpu(mi_le->csum)); in index_check()
79 disk_header->csum = cpu_to_le32(dm_bm_checksum(&disk_header->not_used, in bitmap_prepare_for_write()
100 if (csum_disk != disk_header->csum) { in bitmap_check()
102 le32_to_cpu(csum_disk), le32_to_cpu(disk_header->csum)); in bitmap_check()
/drivers/input/joystick/iforce/
Diforce-serio.c111 iforce->csum += iforce->data[iforce->idx++] = data; in iforce_serio_irq()
121 iforce->csum = 0; in iforce_serio_irq()
/drivers/staging/csr/
Dcsr_wifi_hip_xbv.c752 u16 csum; in write_fwdl_to_ptdl() local
794 csum = calc_checksum(buf, csum_start_offs, written - (csum_start_offs - offset)); in write_fwdl_to_ptdl()
795 written += write_uint16(buf, offset + written, csum); in write_fwdl_to_ptdl()
817 u16 csum; in write_reset_ptdl() local
851 csum = calc_checksum(buf, csum_start_offs, written - (csum_start_offs - offset)); in write_reset_ptdl()
852 written += write_uint16(buf, offset + written, csum); in write_reset_ptdl()
/drivers/input/joystick/
Da3d.c107 int i, csum = 0; in a3d_csum() local
110 csum += data[i]; in a3d_csum()
111 return (csum & 0x3f) != ((data[count - 2] << 3) | data[count - 1]); in a3d_csum()
/drivers/firmware/
Discsi_ibft.c410 u8 csum = 0; in ibft_check_device() local
422 csum += *pos; in ibft_check_device()
424 if (csum) { in ibft_check_device()
425 printk(KERN_ERR "iBFT has incorrect checksum (0x%x)!\n", csum); in ibft_check_device()
/drivers/s390/scsi/
Dzfcp_sysfs.c374 unsigned long long fsum, fmin, fmax, csum, cmin, cmax, cc; \
380 csum = lat->_name.channel.sum * adapter->timer_ticks; \
389 do_div(csum, 1000); \
394 fmin, fmax, fsum, cmin, cmax, csum, cc); \
/drivers/scsi/fnic/
Dvnic_dev.c563 u32 csum; in vnic_dev_notify_ready() local
569 csum = 0; in vnic_dev_notify_ready()
574 csum += words[i]; in vnic_dev_notify_ready()
575 } while (csum != words[0]); in vnic_dev_notify_ready()
/drivers/gpu/drm/ast/
Dast_mode.c995 u32 csum = 0; in copy_cursor_image() local
1019 csum += data32.ul; in copy_cursor_image()
1031 csum += (u32)data16.us; in copy_cursor_image()
1038 return csum; in copy_cursor_image()
1052 u32 csum; in ast_cursor_set() local
1089 csum = copy_cursor_image(src, dst, width, height); in ast_cursor_set()
1096 writel(csum, dst); in ast_cursor_set()

123456