Skip to content

Commit 460370a

Browse files
djbwrafaeljw
authored andcommitted
dax: Fix alloc_dax_region() compile warning
PFN flags are (unsigned long long), fix the alloc_dax_region() calling convention to fix warnings of the form: >> include/linux/pfn_t.h:18:17: warning: large integer implicitly truncated to unsigned type [-Woverflow] #define PFN_DEV (1ULL << (BITS_PER_LONG_LONG - 3)) Reported-by: kbuild test robot <[email protected]> Signed-off-by: Dan Williams <[email protected]> Acked-by: Thomas Gleixner <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent 33dd707 commit 460370a

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

drivers/dax/bus.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ static void dax_region_unregister(void *region)
227227

228228
struct dax_region *alloc_dax_region(struct device *parent, int region_id,
229229
struct resource *res, int target_node, unsigned int align,
230-
unsigned long pfn_flags)
230+
unsigned long long pfn_flags)
231231
{
232232
struct dax_region *dax_region;
233233

drivers/dax/bus.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ struct dax_region;
1111
void dax_region_put(struct dax_region *dax_region);
1212
struct dax_region *alloc_dax_region(struct device *parent, int region_id,
1313
struct resource *res, int target_node, unsigned int align,
14-
unsigned long flags);
14+
unsigned long long flags);
1515

1616
enum dev_dax_subsys {
1717
DEV_DAX_BUS,

drivers/dax/dax-private.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ struct dax_region {
3232
struct device *dev;
3333
unsigned int align;
3434
struct resource res;
35-
unsigned long pfn_flags;
35+
unsigned long long pfn_flags;
3636
};
3737

3838
/**

0 commit comments

Comments
 (0)