diff options
author | Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com> | 2014-01-30 17:47:11 -0500 |
---|---|---|
committer | Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com> | 2014-02-25 12:34:41 -0500 |
commit | dc2a90004ec1aa5b34fe30083fb2273f88b8ff27 (patch) | |
tree | 8847e891ee19fc302088487a0bc4b5732525e401 /drivers/pinctrl/mvebu/pinctrl-mvebu.c | |
parent | 8d898fd5966caefb60aeb1ba6b33a3ff1b768db0 (diff) |
pinctrl: mvebu: remove obsolete per-control name buffer allocation
With the introduction of a global name buffer, we can now remove
the allocation and preparation of per-control name buffers.
Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
Tested-by: Andrew Lunn <andrew@lunn.ch>
Tested-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'drivers/pinctrl/mvebu/pinctrl-mvebu.c')
-rw-r--r-- | drivers/pinctrl/mvebu/pinctrl-mvebu.c | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/drivers/pinctrl/mvebu/pinctrl-mvebu.c b/drivers/pinctrl/mvebu/pinctrl-mvebu.c index d47650fc5119..c0e27e4f8953 100644 --- a/drivers/pinctrl/mvebu/pinctrl-mvebu.c +++ b/drivers/pinctrl/mvebu/pinctrl-mvebu.c | |||
@@ -636,7 +636,6 @@ int mvebu_pinctrl_probe(struct platform_device *pdev) | |||
636 | pctl->desc.npins = 0; | 636 | pctl->desc.npins = 0; |
637 | for (n = 0; n < soc->ncontrols; n++) { | 637 | for (n = 0; n < soc->ncontrols; n++) { |
638 | struct mvebu_mpp_ctrl *ctrl = &soc->controls[n]; | 638 | struct mvebu_mpp_ctrl *ctrl = &soc->controls[n]; |
639 | char *names; | ||
640 | 639 | ||
641 | pctl->desc.npins += ctrl->npins; | 640 | pctl->desc.npins += ctrl->npins; |
642 | /* initial control pins */ | 641 | /* initial control pins */ |
@@ -654,14 +653,6 @@ int mvebu_pinctrl_probe(struct platform_device *pdev) | |||
654 | } | 653 | } |
655 | 654 | ||
656 | /* generic mvebu register control */ | 655 | /* generic mvebu register control */ |
657 | names = devm_kzalloc(&pdev->dev, ctrl->npins * 8, GFP_KERNEL); | ||
658 | if (!names) { | ||
659 | dev_err(&pdev->dev, "failed to alloc mpp names\n"); | ||
660 | return -ENOMEM; | ||
661 | } | ||
662 | for (k = 0; k < ctrl->npins; k++) | ||
663 | sprintf(names + 8*k, "mpp%d", ctrl->pid+k); | ||
664 | ctrl->name = names; | ||
665 | pctl->num_groups += ctrl->npins; | 656 | pctl->num_groups += ctrl->npins; |
666 | noname += ctrl->npins; | 657 | noname += ctrl->npins; |
667 | } | 658 | } |