int omap_st_set_chgain(struct omap_mcbsp *mcbsp, int channel, s16 chgain)
{
- struct omap_mcbsp_st_data *st_data;
+ struct omap_mcbsp_st_data *st_data = mcbsp->st_data;
int ret = 0;
- st_data = mcbsp->st_data;
-
if (!st_data)
return -ENOENT;
int omap_st_get_chgain(struct omap_mcbsp *mcbsp, int channel, s16 *chgain)
{
- struct omap_mcbsp_st_data *st_data;
+ struct omap_mcbsp_st_data *st_data = mcbsp->st_data;
int ret = 0;
- st_data = mcbsp->st_data;
-
if (!st_data)
return -ENOENT;
int omap_st_enable(struct omap_mcbsp *mcbsp)
{
- struct omap_mcbsp_st_data *st_data;
-
- st_data = mcbsp->st_data;
+ struct omap_mcbsp_st_data *st_data = mcbsp->st_data;
if (!st_data)
return -ENODEV;
int omap_st_disable(struct omap_mcbsp *mcbsp)
{
- struct omap_mcbsp_st_data *st_data;
+ struct omap_mcbsp_st_data *st_data = mcbsp->st_data;
int ret = 0;
- st_data = mcbsp->st_data;
-
if (!st_data)
return -ENODEV;
int omap_st_is_enabled(struct omap_mcbsp *mcbsp)
{
- struct omap_mcbsp_st_data *st_data;
-
- st_data = mcbsp->st_data;
+ struct omap_mcbsp_st_data *st_data = mcbsp->st_data;
if (!st_data)
return -ENODEV;
-
return st_data->enabled;
}