msm: camera: Add new soc api
Add a new soc api to set the flags of a clock. CRs-Fixed: 1044373 Change-Id: I81c8ffc49166f7bf6d5c6eb3b61bfb5699dfb091 Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
This commit is contained in:
parent
e94b446eac
commit
2c28d7f5d4
2 changed files with 25 additions and 0 deletions
|
@ -24,6 +24,7 @@
|
||||||
#include <linux/module.h>
|
#include <linux/module.h>
|
||||||
#include <linux/of_platform.h>
|
#include <linux/of_platform.h>
|
||||||
#include <linux/msm-bus.h>
|
#include <linux/msm-bus.h>
|
||||||
|
#include <linux/clk/msm-clk.h>
|
||||||
#include "cam_soc_api.h"
|
#include "cam_soc_api.h"
|
||||||
|
|
||||||
struct msm_cam_bus_pscale_data {
|
struct msm_cam_bus_pscale_data {
|
||||||
|
@ -454,6 +455,17 @@ long msm_camera_clk_set_rate(struct device *dev,
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL(msm_camera_clk_set_rate);
|
EXPORT_SYMBOL(msm_camera_clk_set_rate);
|
||||||
|
|
||||||
|
int msm_camera_set_clk_flags(struct clk *clk, unsigned long flags)
|
||||||
|
{
|
||||||
|
if (!clk)
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
|
CDBG("clk : %p, flags : %ld\n", clk, flags);
|
||||||
|
|
||||||
|
return clk_set_flags(clk, flags);
|
||||||
|
}
|
||||||
|
EXPORT_SYMBOL(msm_camera_set_clk_flags);
|
||||||
|
|
||||||
/* release memory allocated for clocks */
|
/* release memory allocated for clocks */
|
||||||
static int msm_camera_put_clk_info_internal(struct device *dev,
|
static int msm_camera_put_clk_info_internal(struct device *dev,
|
||||||
struct msm_cam_clk_info **clk_info,
|
struct msm_cam_clk_info **clk_info,
|
||||||
|
|
|
@ -187,6 +187,18 @@ int msm_camera_clk_enable(struct device *dev,
|
||||||
long msm_camera_clk_set_rate(struct device *dev,
|
long msm_camera_clk_set_rate(struct device *dev,
|
||||||
struct clk *clk,
|
struct clk *clk,
|
||||||
long clk_rate);
|
long clk_rate);
|
||||||
|
/**
|
||||||
|
* @brief : Sets flags of a clock
|
||||||
|
*
|
||||||
|
* This function will set the flags for a specified clock
|
||||||
|
*
|
||||||
|
* @param clk : Pointer to clock to set flags for
|
||||||
|
* @param flags : The flags to set
|
||||||
|
*
|
||||||
|
* @return Status of operation.
|
||||||
|
*/
|
||||||
|
|
||||||
|
int msm_camera_set_clk_flags(struct clk *clk, unsigned long flags);
|
||||||
/**
|
/**
|
||||||
* @brief : Gets regulator info
|
* @brief : Gets regulator info
|
||||||
*
|
*
|
||||||
|
@ -200,6 +212,7 @@ long msm_camera_clk_set_rate(struct device *dev,
|
||||||
*
|
*
|
||||||
* @return Status of operation. Negative in case of error. Zero otherwise.
|
* @return Status of operation. Negative in case of error. Zero otherwise.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
int msm_camera_get_regulator_info(struct platform_device *pdev,
|
int msm_camera_get_regulator_info(struct platform_device *pdev,
|
||||||
struct msm_cam_regulator **vdd_info, int *num_reg);
|
struct msm_cam_regulator **vdd_info, int *num_reg);
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Add table
Reference in a new issue