Lines Matching refs:rn

408 	struct w1_reg_num *rn)  in w1_atoreg_num()  argument
432 rn->family = family; in w1_atoreg_num()
433 rn->id = id; in w1_atoreg_num()
435 rn64_le = cpu_to_le64(*(u64 *)rn); in w1_atoreg_num()
436 rn->crc = w1_calc_crc8((u8 *)&rn64_le, 7); in w1_atoreg_num()
440 rn->family, (unsigned long long)rn->id, rn->crc); in w1_atoreg_num()
450 struct w1_reg_num *rn) in w1_slave_search_device() argument
455 if (sl->reg_num.family == rn->family && in w1_slave_search_device()
456 sl->reg_num.id == rn->id && in w1_slave_search_device()
457 sl->reg_num.crc == rn->crc) { in w1_slave_search_device()
471 struct w1_reg_num rn; in w1_master_attribute_store_add() local
475 if (w1_atoreg_num(dev, buf, count, &rn)) in w1_master_attribute_store_add()
479 sl = w1_slave_search_device(md, &rn); in w1_master_attribute_store_add()
488 w1_attach_slave_device(md, &rn); in w1_master_attribute_store_add()
509 struct w1_reg_num rn; in w1_master_attribute_store_remove() local
513 if (w1_atoreg_num(dev, buf, count, &rn)) in w1_master_attribute_store_remove()
517 sl = w1_slave_search_device(md, &rn); in w1_master_attribute_store_remove()
524 dev_info(dev, "Device %02x-%012llx doesn't exists\n", rn.family, in w1_master_attribute_store_remove()
525 (unsigned long long)rn.id); in w1_master_attribute_store_remove()
727 int w1_attach_slave_device(struct w1_master *dev, struct w1_reg_num *rn) in w1_attach_slave_device() argument
748 memcpy(&sl->reg_num, rn, sizeof(sl->reg_num)); in w1_attach_slave_device()
753 rn->family, (unsigned long long)rn->id, rn->crc); in w1_attach_slave_device()
757 request_module("w1-family-0x%02X", rn->family); in w1_attach_slave_device()
761 f = w1_family_registered(rn->family); in w1_attach_slave_device()
765 rn->family, rn->family, in w1_attach_slave_device()
766 (unsigned long long)rn->id, rn->crc); in w1_attach_slave_device()
786 memcpy(msg.id.id, rn, sizeof(msg.id)); in w1_attach_slave_device()
905 struct w1_reg_num rn; in w1_reconnect_slaves() local
908 memcpy(&rn, &sl->reg_num, sizeof(rn)); in w1_reconnect_slaves()
913 w1_attach_slave_device(dev, &rn); in w1_reconnect_slaves()
925 void w1_slave_found(struct w1_master *dev, u64 rn) in w1_slave_found() argument
929 u64 rn_le = cpu_to_le64(rn); in w1_slave_found()
933 tmp = (struct w1_reg_num *) &rn; in w1_slave_found()
939 if (rn && tmp->crc == w1_calc_crc8((u8 *)&rn_le, 7)) in w1_slave_found()
965 u64 last_rn, rn, tmp64; in w1_search() local
972 rn = dev->search_id; in w1_search()
980 last_rn = rn; in w1_search()
981 rn = 0; in w1_search()
1000 rv = w1_read_block(dev, (u8 *)&rn, 8); in w1_search()
1003 if (rv == 8 && rn) in w1_search()
1004 cb(dev, rn); in w1_search()
1033 rn |= (tmp64 << i); in w1_search()
1048 dev->search_id = rn; in w1_search()
1051 cb(dev, rn); in w1_search()