Commit b70c9d37 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'rproc-v4.18' of git://github.com/andersson/remoteproc

Pull remoteproc updates from Bjorn Andersson:
 "This brings a few minor fixes to the Davinci driver, drops a orphan
  include file from the StE cleanup done ealier and introduces support
  for booting the modem on Qualcomm's SDM845 platform"

* tag 'rproc-v4.18' of git://github.com/andersson/remoteproc:
  remoteproc: q6v5: Allow defining GLINK edge for mss remoteproc
  remoteproc: q6v5: Add support for mss remoteproc on SDM845
  remoteproc: q6v5: Introduce reset assert/deassert helper functions
  dt-bindings: remoteproc: Add Q6v5 Modem PIL binding for SDM845
  remoteproc: q6v5: Move proxy unvote to handover irq handler
  remoteproc: q6v5: Return irq from q6v5_request_irq()
  remoteproc/ste: remove abandoned include file
  remoteproc/davinci: use octal permissions for module_param()
  remoteproc/davinci: prepare and unprepare the clock where needed
  remoteproc/davinci: add the missing retval check for clk_enable()
  remoteproc: Remove depends on HAS_DMA in case of platform dependency
  remoteproc: Prevent incorrect rproc state on xfer mem ownership failure
parents 6f75edea 4725496e
......@@ -11,6 +11,7 @@ on the Qualcomm Hexagon core.
"qcom,msm8916-mss-pil",
"qcom,msm8974-mss-pil"
"qcom,msm8996-mss-pil"
"qcom,sdm845-mss-pil"
- reg:
Usage: required
......
......@@ -24,7 +24,6 @@ config IMX_REMOTEPROC
config OMAP_REMOTEPROC
tristate "OMAP remoteproc support"
depends on HAS_DMA
depends on ARCH_OMAP4 || SOC_OMAP5
depends on OMAP_IOMMU
select MAILBOX
......
......@@ -25,7 +25,7 @@
#include "remoteproc_internal.h"
static char *da8xx_fw_name;
module_param(da8xx_fw_name, charp, S_IRUGO);
module_param(da8xx_fw_name, charp, 0444);
MODULE_PARM_DESC(da8xx_fw_name,
"Name of DSP firmware file in /lib/firmware (if not specified defaults to 'rproc-dsp-fw')");
......@@ -138,6 +138,7 @@ static int da8xx_rproc_start(struct rproc *rproc)
struct device *dev = rproc->dev.parent;
struct da8xx_rproc *drproc = (struct da8xx_rproc *)rproc->priv;
struct clk *dsp_clk = drproc->dsp_clk;
int ret;
/* hw requires the start (boot) address be on 1KB boundary */
if (rproc->bootaddr & 0x3ff) {
......@@ -148,7 +149,12 @@ static int da8xx_rproc_start(struct rproc *rproc)
writel(rproc->bootaddr, drproc->bootreg);
clk_enable(dsp_clk);
ret = clk_prepare_enable(dsp_clk);
if (ret) {
dev_err(dev, "clk_prepare_enable() failed: %d\n", ret);
return ret;
}
davinci_clk_reset_deassert(dsp_clk);
return 0;
......@@ -159,7 +165,7 @@ static int da8xx_rproc_stop(struct rproc *rproc)
struct da8xx_rproc *drproc = rproc->priv;
davinci_clk_reset_assert(drproc->dsp_clk);
clk_disable(drproc->dsp_clk);
clk_disable_unprepare(drproc->dsp_clk);
return 0;
}
......
This diff is collapsed.
/*
* Copyright (C) ST-Ericsson AB 2012
* Author: Sjur Brendeland / sjur.brandeland@stericsson.com
*
* License terms: GNU General Public License (GPL) version 2
*/
#ifndef __INC_MODEM_DEV_H
#define __INC_MODEM_DEV_H
#include <linux/types.h>
#include <linux/platform_device.h>
struct ste_modem_device;
/**
* struct ste_modem_dev_cb - Callbacks for modem initiated events.
* @kick: Called when the modem kicks the host.
*
* This structure contains callbacks for actions triggered by the modem.
*/
struct ste_modem_dev_cb {
void (*kick)(struct ste_modem_device *mdev, int notify_id);
};
/**
* struct ste_modem_dev_ops - Functions to control modem and modem interface.
*
* @power: Main power switch, used for cold-start or complete power off.
* @kick: Kick the modem.
* @kick_subscribe: Subscribe for notifications from the modem.
* @setup: Provide callback functions to modem device.
*
* This structure contains functions used by the ste remoteproc driver
* to manage the modem.
*/
struct ste_modem_dev_ops {
int (*power)(struct ste_modem_device *mdev, bool on);
int (*kick)(struct ste_modem_device *mdev, int notify_id);
int (*kick_subscribe)(struct ste_modem_device *mdev, int notify_id);
int (*setup)(struct ste_modem_device *mdev,
struct ste_modem_dev_cb *cfg);
};
/**
* struct ste_modem_device - represent the STE modem device
* @pdev: Reference to platform device
* @ops: Operations used to manage the modem.
* @drv_data: Driver private data.
*/
struct ste_modem_device {
struct platform_device pdev;
struct ste_modem_dev_ops ops;
void *drv_data;
};
#endif /*INC_MODEM_DEV_H*/
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment