* [PATCH] media: atomisp: get rid of a warning message
@ 2020-05-26 8:53 Mauro Carvalho Chehab
2020-05-26 9:54 ` Sakari Ailus
0 siblings, 1 reply; 3+ messages in thread
From: Mauro Carvalho Chehab @ 2020-05-26 8:53 UTC (permalink / raw)
Cc: Mauro Carvalho Chehab, Greg Kroah-Hartman, devel, Sakari Ailus
There's a warning message about an unused code. The code that
were using it were commented out, due to a problem causing the
firmware load to fail on the machines we're using for testing.
Change the place where we're commenting the code out, in order
to avoid the warning.
Fixes: 95d1f398c4dc ("media: atomisp: keep the ISP powered on when setting it")
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
.../staging/media/atomisp/pci/atomisp_v4l2.c | 18 ++++++++++++------
1 file changed, 12 insertions(+), 6 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
index b30a2e54067c..c89d477a3948 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
@@ -734,6 +734,10 @@ static int atomisp_mrfld_pre_power_down(struct atomisp_device *isp)
* WA for DDR DVFS enable/disable
* By default, ISP will force DDR DVFS 1600MHz before disable DVFS
*/
+
+#if 0
+// Used only by atomisp_mrfld_power
+
static void punit_ddr_dvfs_enable(bool enable)
{
int door_bell = 1 << 8;
@@ -758,9 +762,12 @@ static void punit_ddr_dvfs_enable(bool enable)
if (max_wait == -1)
pr_info("DDR DVFS, door bell is not cleared within 3ms\n");
}
+#endif
static int atomisp_mrfld_power(struct atomisp_device *isp, bool enable)
{
+// FIXME: at least with ISP2401, the code below causes the driver to break
+#if 0
unsigned long timeout;
u32 val = enable ? MRFLD_ISPSSPM0_IUNIT_POWER_ON :
MRFLD_ISPSSPM0_IUNIT_POWER_OFF;
@@ -817,22 +824,21 @@ static int atomisp_mrfld_power(struct atomisp_device *isp, bool enable)
dev_err(isp->dev, "IUNIT power-%s timeout.\n", enable ? "on" : "off");
return -EBUSY;
+#else
+ return 0;
+#endif
}
/* Workaround for pmu_nc_set_power_state not ready in MRFLD */
int atomisp_mrfld_power_down(struct atomisp_device *isp)
{
- return 0;
-// FIXME: at least with ISP2401, the code below causes the driver to break
-// return atomisp_mrfld_power(isp, false);
+ return atomisp_mrfld_power(isp, false);
}
/* Workaround for pmu_nc_set_power_state not ready in MRFLD */
int atomisp_mrfld_power_up(struct atomisp_device *isp)
{
- return 0;
-// FIXME: at least with ISP2401, the code below causes the driver to break
-// return atomisp_mrfld_power(isp, true);
+ return atomisp_mrfld_power(isp, true);
}
int atomisp_runtime_suspend(struct device *dev)
--
2.26.2
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] media: atomisp: get rid of a warning message
2020-05-26 8:53 [PATCH] media: atomisp: get rid of a warning message Mauro Carvalho Chehab
@ 2020-05-26 9:54 ` Sakari Ailus
2020-05-26 10:13 ` Mauro Carvalho Chehab
0 siblings, 1 reply; 3+ messages in thread
From: Sakari Ailus @ 2020-05-26 9:54 UTC (permalink / raw)
To: Mauro Carvalho Chehab; +Cc: devel, Greg Kroah-Hartman
On Tue, May 26, 2020 at 10:53:57AM +0200, Mauro Carvalho Chehab wrote:
> There's a warning message about an unused code. The code that
> were using it were commented out, due to a problem causing the
> firmware load to fail on the machines we're using for testing.
>
> Change the place where we're commenting the code out, in order
> to avoid the warning.
>
> Fixes: 95d1f398c4dc ("media: atomisp: keep the ISP powered on when setting it")
> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Note that some of this may be needed to power on some parts of the
hardware on some platforms.
--
Sakari Ailus
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] media: atomisp: get rid of a warning message
2020-05-26 9:54 ` Sakari Ailus
@ 2020-05-26 10:13 ` Mauro Carvalho Chehab
0 siblings, 0 replies; 3+ messages in thread
From: Mauro Carvalho Chehab @ 2020-05-26 10:13 UTC (permalink / raw)
To: Sakari Ailus; +Cc: devel, Greg Kroah-Hartman
Em Tue, 26 May 2020 12:54:18 +0300
Sakari Ailus <sakari.ailus@linux.intel.com> escreveu:
> On Tue, May 26, 2020 at 10:53:57AM +0200, Mauro Carvalho Chehab wrote:
> > There's a warning message about an unused code. The code that
> > were using it were commented out, due to a problem causing the
> > firmware load to fail on the machines we're using for testing.
> >
> > Change the place where we're commenting the code out, in order
> > to avoid the warning.
> >
> > Fixes: 95d1f398c4dc ("media: atomisp: keep the ISP powered on when setting it")
> > Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
>
> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
>
> Note that some of this may be needed to power on some parts of the
> hardware on some platforms.
Yes, I know. That's why I'm preserving the code over there.
This driver is supposed to work on 4 different types of Atom CPU:
#define __IS_SOC(x) (boot_cpu_data.x86_vendor == X86_VENDOR_INTEL && \
boot_cpu_data.x86 == 6 && \
boot_cpu_data.x86_model == x)
#define IS_MFLD __IS_SOC(0x27)
#define IS_BYT __IS_SOC(0x37)
#define IS_CHT __IS_SOC(0x4C)
#define IS_MOFD __IS_SOC(0x5A)
Right now, I have just the CHT hardware for testing.
Thanks,
Mauro
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-05-26 10:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-26 8:53 [PATCH] media: atomisp: get rid of a warning message Mauro Carvalho Chehab
2020-05-26 9:54 ` Sakari Ailus
2020-05-26 10:13 ` Mauro Carvalho Chehab
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).