aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/pci/msi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c
index 36bc7c415af7..a83c1f5735d6 100644
--- a/drivers/pci/msi.c
+++ b/drivers/pci/msi.c
@@ -47,13 +47,13 @@ msi_register(struct msi_ops *ops)
47 47
48static void msi_cache_ctor(void *p, kmem_cache_t *cache, unsigned long flags) 48static void msi_cache_ctor(void *p, kmem_cache_t *cache, unsigned long flags)
49{ 49{
50 memset(p, 0, NR_IRQS * sizeof(struct msi_desc)); 50 memset(p, 0, sizeof(struct msi_desc));
51} 51}
52 52
53static int msi_cache_init(void) 53static int msi_cache_init(void)
54{ 54{
55 msi_cachep = kmem_cache_create("msi_cache", 55 msi_cachep = kmem_cache_create("msi_cache",
56 NR_IRQS * sizeof(struct msi_desc), 56 sizeof(struct msi_desc),
57 0, SLAB_HWCACHE_ALIGN, msi_cache_ctor, NULL); 57 0, SLAB_HWCACHE_ALIGN, msi_cache_ctor, NULL);
58 if (!msi_cachep) 58 if (!msi_cachep)
59 return -ENOMEM; 59 return -ENOMEM;