diff options
| author | Linux Build Service Account <lnxbuild@localhost> | 2016-09-02 13:52:11 -0700 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2016-09-02 13:52:10 -0700 |
| commit | b11aa41c032c9bfac5b9309de853b78c9a37d05c (patch) | |
| tree | 4fa5708c3d4cb79ae118311731849632618b832b | |
| parent | 340e0f63ff5517447016c991c683d983935f28db (diff) | |
| parent | cfa715d77e4c778ca5b22861d56e3a1755a7314b (diff) | |
Merge "msm: pcie: correct size of local PCIe clock frequency buffer"
| -rw-r--r-- | drivers/pci/host/pci-msm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pci/host/pci-msm.c b/drivers/pci/host/pci-msm.c index e278aab1e530..d8141097b2db 100644 --- a/drivers/pci/host/pci-msm.c +++ b/drivers/pci/host/pci-msm.c @@ -3921,8 +3921,8 @@ static int msm_pcie_get_resources(struct msm_pcie_dev_t *dev, cnt = of_property_count_strings((&pdev->dev)->of_node, "clock-names"); if (cnt > 0) { - clkfreq = kzalloc(cnt * sizeof(*clkfreq), - GFP_KERNEL); + clkfreq = kzalloc((MSM_PCIE_MAX_CLK + MSM_PCIE_MAX_PIPE_CLK) * + sizeof(*clkfreq), GFP_KERNEL); if (!clkfreq) { PCIE_ERR(dev, "PCIe: memory alloc failed for RC%d\n", dev->rc_idx); |
