@@ -297,23 +297,23 @@ static struct scrub_block *alloc_scrub_block(struct scrub_ctx *sctx,
297
297
* Will also allocate new pages for @sblock if needed.
298
298
*/
299
299
static struct scrub_sector * alloc_scrub_sector (struct scrub_block * sblock ,
300
- u64 logical , gfp_t gfp )
300
+ u64 logical )
301
301
{
302
302
const pgoff_t page_index = (logical - sblock -> logical ) >> PAGE_SHIFT ;
303
303
struct scrub_sector * ssector ;
304
304
305
305
/* We must never have scrub_block exceed U32_MAX in size. */
306
306
ASSERT (logical - sblock -> logical < U32_MAX );
307
307
308
- ssector = kzalloc (sizeof (* ssector ), gfp );
308
+ ssector = kzalloc (sizeof (* ssector ), GFP_KERNEL );
309
309
if (!ssector )
310
310
return NULL ;
311
311
312
312
/* Allocate a new page if the slot is not allocated */
313
313
if (!sblock -> pages [page_index ]) {
314
314
int ret ;
315
315
316
- sblock -> pages [page_index ] = alloc_page (gfp );
316
+ sblock -> pages [page_index ] = alloc_page (GFP_KERNEL );
317
317
if (!sblock -> pages [page_index ]) {
318
318
kfree (ssector );
319
319
return NULL ;
@@ -1516,7 +1516,7 @@ static int scrub_setup_recheck_block(struct scrub_block *original_sblock,
1516
1516
sblock = sblocks_for_recheck [mirror_index ];
1517
1517
sblock -> sctx = sctx ;
1518
1518
1519
- sector = alloc_scrub_sector (sblock , logical , GFP_KERNEL );
1519
+ sector = alloc_scrub_sector (sblock , logical );
1520
1520
if (!sector ) {
1521
1521
spin_lock (& sctx -> stat_lock );
1522
1522
sctx -> stat .malloc_errors ++ ;
@@ -2438,7 +2438,7 @@ static int scrub_sectors(struct scrub_ctx *sctx, u64 logical, u32 len,
2438
2438
*/
2439
2439
u32 l = min (sectorsize , len );
2440
2440
2441
- sector = alloc_scrub_sector (sblock , logical , GFP_KERNEL );
2441
+ sector = alloc_scrub_sector (sblock , logical );
2442
2442
if (!sector ) {
2443
2443
spin_lock (& sctx -> stat_lock );
2444
2444
sctx -> stat .malloc_errors ++ ;
@@ -2775,7 +2775,7 @@ static int scrub_sectors_for_parity(struct scrub_parity *sparity,
2775
2775
for (index = 0 ; len > 0 ; index ++ ) {
2776
2776
struct scrub_sector * sector ;
2777
2777
2778
- sector = alloc_scrub_sector (sblock , logical , GFP_KERNEL );
2778
+ sector = alloc_scrub_sector (sblock , logical );
2779
2779
if (!sector ) {
2780
2780
spin_lock (& sctx -> stat_lock );
2781
2781
sctx -> stat .malloc_errors ++ ;
0 commit comments