Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6689076f authored by Mitchel Humpherys's avatar Mitchel Humpherys
Browse files

iommu: msm: move msm_iommu_register_notify



It's currently inside an `#ifdef CONFIG_MSM_IOMMU_VBIF_CHECK', which is
incorrect since it doesn't actually depend on that config.  Drivers that
want to use it fail to link when CONFIG_MSM_IOMMU_V1=y &&
CONFIG_MSM_IOMMU_VBIF_CHECK=n.  Move it out and export it while we're at
it.

Change-Id: I48dc655fbd1558871704aa40e065e1002e836308
Signed-off-by: default avatarMitchel Humpherys <mitchelh@codeaurora.org>
parent 092ffeaf
Loading
Loading
Loading
Loading
+9 −8
Original line number Diff line number Diff line
/* Copyright (c) 2012-2014, The Linux Foundation. All rights reserved.
/* Copyright (c) 2012-2015, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -177,6 +177,14 @@ struct iommu_access_ops iommu_access_ops_v1 = {
	.iommu_lock_release = _iommu_lock_release,
};

static BLOCKING_NOTIFIER_HEAD(msm_iommu_notifier_list);

void msm_iommu_register_notify(struct notifier_block *nb)
{
	blocking_notifier_chain_register(&msm_iommu_notifier_list, nb);
}
EXPORT_SYMBOL(msm_iommu_register_notify);

#ifdef CONFIG_MSM_IOMMU_VBIF_CHECK

#define VBIF_XIN_HALT_CTRL0 0x200
@@ -253,13 +261,6 @@ static void check_halt_state(struct msm_iommu_drvdata const *drvdata)
	BUG();
}

static BLOCKING_NOTIFIER_HEAD(msm_iommu_notifier_list);

void msm_iommu_register_notify(struct notifier_block *nb)
{
	blocking_notifier_chain_register(&msm_iommu_notifier_list, nb);
}

static void check_tlb_sync_state(struct msm_iommu_drvdata const *drvdata,
				int ctx, struct msm_iommu_priv *priv)
{