mirror of
https://codeberg.org/shufflecake/shufflecake-c.git
synced 2026-01-04 18:15:27 -05:00
fix: Undefine BLK_STS_INVAL
This symbol seems to be only supported in recent kernels, so remvoing it for now to allow compilation on older kernels
This commit is contained in:
parent
5b0d030780
commit
b253a92cba
1 changed files with 2 additions and 2 deletions
|
|
@ -137,7 +137,7 @@ static int sflite_map(struct dm_target *ti, struct bio *bio)
|
|||
if (unlikely(bio->bi_iter.bi_size != SFLITE_BLOCK_SIZE * SFLITE_SLICE_SCALE)) {
|
||||
DMINFO("Wrong discard bio size: %u", bio->bi_iter.bi_size);
|
||||
// TODO investigate where these are coming from
|
||||
bio->bi_status = BLK_STS_INVAL;
|
||||
//bio->bi_status = BLK_STS_INVAL; // BUG: this only seems to work on recent (>6.8) kernels
|
||||
bio_endio(bio);
|
||||
return DM_MAPIO_SUBMITTED;
|
||||
}
|
||||
|
|
@ -145,7 +145,7 @@ static int sflite_map(struct dm_target *ti, struct bio *bio)
|
|||
/* Ensure the logical block number is aligned with the beginning of a slice */
|
||||
if (unlikely(lblk_num % SFLITE_SLICE_SCALE != 0)) {
|
||||
DMWARN("Unaligned discard bio!");
|
||||
bio->bi_status = BLK_STS_INVAL;
|
||||
//bio->bi_status = BLK_STS_INVAL; // BUG: this only seems to work on recent (>6.8) kernels
|
||||
bio_endio(bio);
|
||||
return DM_MAPIO_SUBMITTED;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue