diff options
Diffstat (limited to 'drivers/lightnvm/rrpc.c')
| -rw-r--r-- | drivers/lightnvm/rrpc.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/drivers/lightnvm/rrpc.c b/drivers/lightnvm/rrpc.c index 34d2ebf90ed6..88e0d0677b09 100644 --- a/drivers/lightnvm/rrpc.c +++ b/drivers/lightnvm/rrpc.c | |||
| @@ -1126,7 +1126,6 @@ static void rrpc_core_free(struct rrpc *rrpc) | |||
| 1126 | 1126 | ||
| 1127 | static void rrpc_luns_free(struct rrpc *rrpc) | 1127 | static void rrpc_luns_free(struct rrpc *rrpc) |
| 1128 | { | 1128 | { |
| 1129 | struct nvm_dev *dev = rrpc->dev; | ||
| 1130 | struct nvm_lun *lun; | 1129 | struct nvm_lun *lun; |
| 1131 | struct rrpc_lun *rlun; | 1130 | struct rrpc_lun *rlun; |
| 1132 | int i; | 1131 | int i; |
| @@ -1139,7 +1138,6 @@ static void rrpc_luns_free(struct rrpc *rrpc) | |||
| 1139 | lun = rlun->parent; | 1138 | lun = rlun->parent; |
| 1140 | if (!lun) | 1139 | if (!lun) |
| 1141 | break; | 1140 | break; |
| 1142 | dev->mt->release_lun(dev, lun->id); | ||
| 1143 | vfree(rlun->blocks); | 1141 | vfree(rlun->blocks); |
| 1144 | } | 1142 | } |
| 1145 | 1143 | ||
| @@ -1169,11 +1167,6 @@ static int rrpc_luns_init(struct rrpc *rrpc, int lun_begin, int lun_end) | |||
| 1169 | int lunid = lun_begin + i; | 1167 | int lunid = lun_begin + i; |
| 1170 | struct nvm_lun *lun; | 1168 | struct nvm_lun *lun; |
| 1171 | 1169 | ||
| 1172 | if (dev->mt->reserve_lun(dev, lunid)) { | ||
| 1173 | pr_err("rrpc: lun %u is already allocated\n", lunid); | ||
| 1174 | goto err; | ||
| 1175 | } | ||
| 1176 | |||
| 1177 | lun = dev->mt->get_lun(dev, lunid); | 1170 | lun = dev->mt->get_lun(dev, lunid); |
| 1178 | if (!lun) | 1171 | if (!lun) |
| 1179 | goto err; | 1172 | goto err; |
