(ISO15693_REQ_FLAG_SUB_CARRIER | ISO15693_REQ_FLAG_DATA_RATE)
enum trf7970a_state {
- TRF7970A_ST_OFF,
+ TRF7970A_ST_RF_OFF,
TRF7970A_ST_IDLE,
TRF7970A_ST_IDLE_RX_BLOCKED,
TRF7970A_ST_WAIT_FOR_TX_FIFO,
mutex_lock(&trf->lock);
- if (trf->state == TRF7970A_ST_OFF) {
+ if (trf->state == TRF7970A_ST_RF_OFF) {
mutex_unlock(&trf->lock);
return IRQ_NONE;
}
trf7970a_write(trf, TRF7970A_CHIP_STATUS_CTRL, trf->chip_status_ctrl);
trf->aborting = false;
- trf->state = TRF7970A_ST_OFF;
+ trf->state = TRF7970A_ST_RF_OFF;
pm_runtime_mark_last_busy(trf->dev);
pm_runtime_put_autosuspend(trf->dev);
if (on) {
switch (trf->state) {
- case TRF7970A_ST_OFF:
+ case TRF7970A_ST_RF_OFF:
ret = trf7970a_switch_rf_on(trf);
break;
case TRF7970A_ST_IDLE:
}
} else {
switch (trf->state) {
- case TRF7970A_ST_OFF:
+ case TRF7970A_ST_RF_OFF:
break;
default:
dev_err(trf->dev, "%s - Invalid request: %d %d\n",
mutex_lock(&trf->lock);
- if (trf->state == TRF7970A_ST_OFF) {
+ if (trf->state == TRF7970A_ST_RF_OFF) {
ret = trf7970a_switch_rf_on(trf);
if (ret)
goto err_unlock;
if (!trf)
return -ENOMEM;
- trf->state = TRF7970A_ST_OFF;
+ trf->state = TRF7970A_ST_RF_OFF;
trf->dev = &spi->dev;
trf->spi = spi;
dev_dbg(dev, "Runtime suspend\n");
- if (trf->state != TRF7970A_ST_OFF) {
+ if (trf->state != TRF7970A_ST_RF_OFF) {
dev_dbg(dev, "Can't suspend - not in OFF state (%d)\n",
trf->state);
return -EBUSY;