Lines Matching refs:cmsg
504 static void process_add_new_disk(struct mddev *mddev, struct cluster_msg *cmsg) in process_add_new_disk() argument
514 sprintf(disk_uuid + len, "%pU", cmsg->uuid); in process_add_new_disk()
515 snprintf(raid_slot, 16, "RAID_DISK=%d", le32_to_cpu(cmsg->raid_slot)); in process_add_new_disk()
733 static int __sendmsg(struct md_cluster_info *cinfo, struct cluster_msg *cmsg) in __sendmsg() argument
738 cmsg->slot = cpu_to_le32(slot); in __sendmsg()
746 memcpy(cinfo->message_lockres->lksb.sb_lvbptr, (void *)cmsg, in __sendmsg()
784 static int sendmsg(struct md_cluster_info *cinfo, struct cluster_msg *cmsg, in sendmsg() argument
791 ret = __sendmsg(cinfo, cmsg); in sendmsg()
981 struct cluster_msg cmsg = {0}; in resync_bitmap() local
984 cmsg.type = cpu_to_le32(BITMAP_NEEDS_SYNC); in resync_bitmap()
985 err = sendmsg(cinfo, &cmsg, 1); in resync_bitmap()
1076 struct cluster_msg cmsg; in metadata_update_finish() local
1081 memset(&cmsg, 0, sizeof(cmsg)); in metadata_update_finish()
1082 cmsg.type = cpu_to_le32(METADATA_UPDATED); in metadata_update_finish()
1091 cmsg.raid_slot = cpu_to_le32(raid_slot); in metadata_update_finish()
1092 ret = __sendmsg(cinfo, &cmsg); in metadata_update_finish()
1110 struct cluster_msg cmsg = {0}; in update_bitmap_size() local
1113 cmsg.type = cpu_to_le32(BITMAP_RESIZE); in update_bitmap_size()
1114 cmsg.high = cpu_to_le64(size); in update_bitmap_size()
1115 ret = sendmsg(cinfo, &cmsg, 0); in update_bitmap_size()
1256 struct cluster_msg cmsg; in update_size() local
1267 memset(&cmsg, 0, sizeof(cmsg)); in update_size()
1268 cmsg.type = cpu_to_le32(METADATA_UPDATED); in update_size()
1275 cmsg.raid_slot = cpu_to_le32(raid_slot); in update_size()
1281 ret = __sendmsg(cinfo, &cmsg); in update_size()
1300 memset(&cmsg, 0, sizeof(cmsg)); in update_size()
1301 cmsg.type = cpu_to_le32(CHANGE_CAPACITY); in update_size()
1302 ret = __sendmsg(cinfo, &cmsg); in update_size()
1310 ret = __sendmsg(cinfo, &cmsg); in update_size()
1338 struct cluster_msg cmsg = {0}; in resync_info_update() local
1350 cmsg.type = cpu_to_le32(RESYNCING); in resync_info_update()
1351 cmsg.low = cpu_to_le64(lo); in resync_info_update()
1352 cmsg.high = cpu_to_le64(hi); in resync_info_update()
1359 return sendmsg(cinfo, &cmsg, 1); in resync_info_update()
1361 return sendmsg(cinfo, &cmsg, 0); in resync_info_update()
1405 struct cluster_msg cmsg; in add_new_disk() local
1410 memset(&cmsg, 0, sizeof(cmsg)); in add_new_disk()
1411 cmsg.type = cpu_to_le32(NEWDISK); in add_new_disk()
1412 memcpy(cmsg.uuid, uuid, 16); in add_new_disk()
1413 cmsg.raid_slot = cpu_to_le32(rdev->desc_nr); in add_new_disk()
1416 ret = __sendmsg(cinfo, &cmsg); in add_new_disk()
1473 struct cluster_msg cmsg = {0}; in remove_disk() local
1475 cmsg.type = cpu_to_le32(REMOVE); in remove_disk()
1476 cmsg.raid_slot = cpu_to_le32(rdev->desc_nr); in remove_disk()
1477 return sendmsg(cinfo, &cmsg, 1); in remove_disk()
1536 struct cluster_msg cmsg = {0}; in gather_bitmaps() local
1540 cmsg.type = cpu_to_le32(RE_ADD); in gather_bitmaps()
1541 cmsg.raid_slot = cpu_to_le32(rdev->desc_nr); in gather_bitmaps()
1542 err = sendmsg(cinfo, &cmsg, 1); in gather_bitmaps()