summaryrefslogtreecommitdiff
path: root/drivers/staging/fsl_qbman/bman_driver.c
diff options
context:
space:
mode:
authorHaiying Wang <Haiying.Wang@freescale.com>2013-10-24 19:14:56 (GMT)
committerJ. German Rivera <German.Rivera@freescale.com>2013-11-14 17:16:09 (GMT)
commit9948be94b72fca028bc139370d6090bda15a73f8 (patch)
tree430d75726bfc27abc2bdb1b3698da296b641f14e /drivers/staging/fsl_qbman/bman_driver.c
parentb3448f1761582552058d171f06d4a21ee425d821 (diff)
downloadlinux-fsl-qoriq-9948be94b72fca028bc139370d6090bda15a73f8.tar.xz
fsl_qbman: remove the portal migration functions
Because we only need to change the portal irq affinity and/or sdest for hotplug, we don't really migrate the portal. Also because the irq and sdest are updated via qm_portal_config object, as such, we move the code from *_high.c to *_driver.c. Signed-off-by: Haiying Wang <Haiying.Wang@freescale.com> Change-Id: I937e6b6195e6e701d03a8cf738e6fa8e6afa260c Reviewed-on: http://git.am.freescale.net:8181/6040 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Geoff Thorpe <Geoff.Thorpe@freescale.com> Reviewed-by: Jose Rivera <German.Rivera@freescale.com>
Diffstat (limited to 'drivers/staging/fsl_qbman/bman_driver.c')
-rw-r--r--drivers/staging/fsl_qbman/bman_driver.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/drivers/staging/fsl_qbman/bman_driver.c b/drivers/staging/fsl_qbman/bman_driver.c
index 513c7f1..d71301c 100644
--- a/drivers/staging/fsl_qbman/bman_driver.c
+++ b/drivers/staging/fsl_qbman/bman_driver.c
@@ -296,18 +296,26 @@ __setup("bportals=", parse_bportals);
static void bman_offline_cpu(unsigned int cpu)
{
struct bman_portal *p;
+ const struct bm_portal_config *pcfg;
p = (struct bman_portal *)affine_bportals[cpu];
- if (p && (!bman_portal_is_sharing_redirect(p)))
- bman_migrate_portal(p);
+ if (p) {
+ pcfg = bman_get_bm_portal_config(p);
+ if (pcfg)
+ irq_set_affinity(pcfg->public_cfg.irq, cpumask_of(0));
+ }
}
#ifdef CONFIG_HOTPLUG_CPU
static void bman_online_cpu(unsigned int cpu)
{
struct bman_portal *p;
+ const struct bm_portal_config *pcfg;
p = (struct bman_portal *)affine_bportals[cpu];
- if (p && (!bman_portal_is_sharing_redirect(p)))
- bman_migrate_portal_back(p, cpu);
+ if (p) {
+ pcfg = bman_get_bm_portal_config(p);
+ if (pcfg)
+ irq_set_affinity(pcfg->public_cfg.irq, cpumask_of(cpu));
+ }
}
static int __cpuinit bman_hotplug_cpu_callback(struct notifier_block *nfb,