Lines Matching refs:state
38 enum myrb_devstate state;
49 static const char *myrb_devstate_name(enum myrb_devstate state)
55 if (entry[i].state == state)
407 if (new->state == MYRB_DEVICE_OFFLINE)
410 "Adding Logical Drive %d in state %s\n",
411 ldev_num, myrb_devstate_name(new->state));
417 if (new->state != old->state)
420 ldev_num, myrb_devstate_name(new->state));
777 * myrb_set_pdev_state - sets the device state for a physical device
782 struct scsi_device *sdev, enum myrb_devstate state)
793 mbox->type3D.state = state & 0x1F;
1437 if (ldev_info->state != MYRB_DEVICE_ONLINE &&
1438 ldev_info->state != MYRB_DEVICE_WO) {
1439 dev_dbg(&shost->shost_gendev, "ldev %u in state %x, skip\n",
1440 sdev->id, ldev_info ? ldev_info->state : 0xff);
1523 if (ldev_info->state == MYRB_DEVICE_WO) {
1540 if (ldev_info->state == MYRB_DEVICE_WO) {
1557 if (ldev_info->state == MYRB_DEVICE_WO) {
1666 "slave alloc ldev %d state %x\n",
1667 ldev_num, ldev_info->state);
1714 "Failed to get device state, status %x\n",
1726 "slave alloc pdev %d:%d state %x\n",
1727 sdev->channel, sdev->id, pdev_info->state);
1764 if (ldev_info->state != MYRB_DEVICE_ONLINE)
1767 myrb_devstate_name(ldev_info->state));
1804 name = myrb_devstate_name(ldev_info->state);
1809 ldev_info->state);
1819 "Failed to get device state, status %x\n",
1825 name = myrb_devstate_name(pdev_info->state);
1830 pdev_info->state);
1866 if (pdev_info->state == new_state)
1918 ldev_info->state);
2293 enum raid_state state = RAID_STATE_UNKNOWN;
2297 state = RAID_STATE_UNKNOWN;
2301 state = RAID_STATE_RESYNCING;
2303 switch (ldev_info->state) {
2305 state = RAID_STATE_ACTIVE;
2309 state = RAID_STATE_DEGRADED;
2312 state = RAID_STATE_OFFLINE;
2316 raid_set_state(myrb_raid_template, dev, state);
3314 static inline void myrb_translate_devstate(void *state)
3316 memcpy(state + 2, state + 3, 1);
3317 memmove(state + 4, state + 5, 2);
3318 memmove(state + 6, state + 8, 4);