aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/dwc3/core.c
diff options
context:
space:
mode:
authorFelipe Balbi <felipe.balbi@linux.intel.com>2016-10-14 16:28:32 +0300
committerFelipe Balbi <felipe.balbi@linux.intel.com>2016-11-03 10:38:34 +0200
commit3b2733227f4018ea0be44c477806cfd3bf819f0b (patch)
treeb6af322156e90630d84f4ddfa568694fa4903051 /drivers/usb/dwc3/core.c
parentusb: dwc3: core: introduce dwc3_core_setup_global_control() (diff)
downloadlinux-dev-3b2733227f4018ea0be44c477806cfd3bf819f0b.tar.xz
linux-dev-3b2733227f4018ea0be44c477806cfd3bf819f0b.zip
usb: dwc3: core: remove unnecessary alignment
Kernel will give us page aligned memory anyway. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Diffstat (limited to 'drivers/usb/dwc3/core.c')
-rw-r--r--drivers/usb/dwc3/core.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index e65f30afb89a..1f33abf21e0f 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -948,8 +948,6 @@ static void dwc3_core_exit_mode(struct dwc3 *dwc)
}
}
-#define DWC3_ALIGN_MASK (16 - 1)
-
static int dwc3_probe(struct platform_device *pdev)
{
struct device *dev = &pdev->dev;
@@ -962,13 +960,11 @@ static int dwc3_probe(struct platform_device *pdev)
int ret;
void __iomem *regs;
- void *mem;
- mem = devm_kzalloc(dev, sizeof(*dwc) + DWC3_ALIGN_MASK, GFP_KERNEL);
- if (!mem)
+ dwc = devm_kzalloc(dev, sizeof(*dwc), GFP_KERNEL);
+ if (!dwc)
return -ENOMEM;
- dwc = PTR_ALIGN(mem, DWC3_ALIGN_MASK + 1);
dwc->dev = dev;
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);