Lines Matching refs:rn

404 	struct w1_reg_num *rn)  in w1_atoreg_num()  argument
428 rn->family = family; in w1_atoreg_num()
429 rn->id = id; in w1_atoreg_num()
431 rn64_le = cpu_to_le64(*(u64 *)rn); in w1_atoreg_num()
432 rn->crc = w1_calc_crc8((u8 *)&rn64_le, 7); in w1_atoreg_num()
436 rn->family, (unsigned long long)rn->id, rn->crc); in w1_atoreg_num()
446 struct w1_reg_num *rn) in w1_slave_search_device() argument
451 if (sl->reg_num.family == rn->family && in w1_slave_search_device()
452 sl->reg_num.id == rn->id && in w1_slave_search_device()
453 sl->reg_num.crc == rn->crc) { in w1_slave_search_device()
467 struct w1_reg_num rn; in w1_master_attribute_store_add() local
471 if (w1_atoreg_num(dev, buf, count, &rn)) in w1_master_attribute_store_add()
475 sl = w1_slave_search_device(md, &rn); in w1_master_attribute_store_add()
484 w1_attach_slave_device(md, &rn); in w1_master_attribute_store_add()
505 struct w1_reg_num rn; in w1_master_attribute_store_remove() local
509 if (w1_atoreg_num(dev, buf, count, &rn)) in w1_master_attribute_store_remove()
513 sl = w1_slave_search_device(md, &rn); in w1_master_attribute_store_remove()
520 dev_info(dev, "Device %02x-%012llx doesn't exists\n", rn.family, in w1_master_attribute_store_remove()
521 (unsigned long long)rn.id); in w1_master_attribute_store_remove()
703 int w1_attach_slave_device(struct w1_master *dev, struct w1_reg_num *rn) in w1_attach_slave_device() argument
724 memcpy(&sl->reg_num, rn, sizeof(sl->reg_num)); in w1_attach_slave_device()
730 request_module("w1-family-0x%02x", rn->family); in w1_attach_slave_device()
734 f = w1_family_registered(rn->family); in w1_attach_slave_device()
738 rn->family, rn->family, in w1_attach_slave_device()
739 (unsigned long long)rn->id, rn->crc); in w1_attach_slave_device()
759 memcpy(msg.id.id, rn, sizeof(msg.id)); in w1_attach_slave_device()
878 struct w1_reg_num rn; in w1_reconnect_slaves() local
881 memcpy(&rn, &sl->reg_num, sizeof(rn)); in w1_reconnect_slaves()
886 w1_attach_slave_device(dev, &rn); in w1_reconnect_slaves()
898 void w1_slave_found(struct w1_master *dev, u64 rn) in w1_slave_found() argument
902 u64 rn_le = cpu_to_le64(rn); in w1_slave_found()
906 tmp = (struct w1_reg_num *) &rn; in w1_slave_found()
912 if (rn && tmp->crc == w1_calc_crc8((u8 *)&rn_le, 7)) in w1_slave_found()
938 u64 last_rn, rn, tmp64; in w1_search() local
945 rn = dev->search_id; in w1_search()
953 last_rn = rn; in w1_search()
954 rn = 0; in w1_search()
973 rv = w1_read_block(dev, (u8 *)&rn, 8); in w1_search()
976 if (rv == 8 && rn) in w1_search()
977 cb(dev, rn); in w1_search()
1006 rn |= (tmp64 << i); in w1_search()
1021 dev->search_id = rn; in w1_search()
1024 cb(dev, rn); in w1_search()