diff options
author | Ken Adams <kadams@nvidia.com> | 2011-09-21 19:12:01 -0400 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2011-11-30 21:49:03 -0800 |
commit | d03d3fdc6909d8721e6630ef2951326dbdc3700f (patch) | |
tree | 83862bc63adc13a287f5846603a2e3adefde0266 /drivers/video/tegra/host/t20 | |
parent | bd8008b609e0d3ab34ec93df2844c64c69b72a59 (diff) |
video: tegra: host: fix checkpatch.pl issues
The only warnings left are one for
"./nvhost_cdma.c: 609: WARNING: consider using a completion"
and all "over 80 char line" warnings.
Change-Id: I5aa113dac1deb60570c326976baba96386b041ec
Reviewed-on: http://git-master/r/53842
Reviewed-by: Ken Adams <kadams@nvidia.com>
Tested-by: Ken Adams <kadams@nvidia.com>
Reviewed-by: Scott Williams <scwilliams@nvidia.com>
Reviewed-by: Jeff Smith <jsmith@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Rebase-Id: R83200f349310910a04705d0f7a94d8163e0666fe
Diffstat (limited to 'drivers/video/tegra/host/t20')
-rw-r--r-- | drivers/video/tegra/host/t20/cdma_t20.c | 2 | ||||
-rw-r--r-- | drivers/video/tegra/host/t20/channel_t20.c | 5 | ||||
-rw-r--r-- | drivers/video/tegra/host/t20/debug_t20.c | 4 | ||||
-rw-r--r-- | drivers/video/tegra/host/t20/intr_t20.c | 18 |
4 files changed, 23 insertions, 6 deletions
diff --git a/drivers/video/tegra/host/t20/cdma_t20.c b/drivers/video/tegra/host/t20/cdma_t20.c index 772a7d043e51..130cf08e8c6c 100644 --- a/drivers/video/tegra/host/t20/cdma_t20.c +++ b/drivers/video/tegra/host/t20/cdma_t20.c @@ -127,7 +127,7 @@ static void t20_push_buffer_push_to(struct push_buffer *pb, struct nvmap_handle *handle, u32 op1, u32 op2) { u32 cur = pb->cur; - u32 *p = (u32*)((u32)pb->mapped + cur); + u32 *p = (u32 *)((u32)pb->mapped + cur); BUG_ON(cur == pb->fence); *(p++) = op1; *(p++) = op2; diff --git a/drivers/video/tegra/host/t20/channel_t20.c b/drivers/video/tegra/host/t20/channel_t20.c index 7a3e4895e3b1..d1c0b1f72066 100644 --- a/drivers/video/tegra/host/t20/channel_t20.c +++ b/drivers/video/tegra/host/t20/channel_t20.c @@ -105,7 +105,7 @@ const struct nvhost_channeldesc nvhost_t20_channelmap[] = { .name = "dsi", .syncpts = BIT(NVSYNCPT_DSI), .modulemutexes = BIT(NVMODMUTEX_DSI), -}}; +} }; static inline void __iomem *t20_channel_aperture(void __iomem *p, int ndx) { @@ -273,8 +273,7 @@ static int t20_channel_submit(struct nvhost_channel *channel, nvhost_class_host_incr_syncpt_base( NVWAITBASE_3D, user_syncpt_incrs)); - } - else { + } else { /* push user gathers */ int i = 0; for ( ; i < gather_end-gather; i += 2) { diff --git a/drivers/video/tegra/host/t20/debug_t20.c b/drivers/video/tegra/host/t20/debug_t20.c index d3329bf2ed9e..fb101230cd8b 100644 --- a/drivers/video/tegra/host/t20/debug_t20.c +++ b/drivers/video/tegra/host/t20/debug_t20.c @@ -21,7 +21,7 @@ #include <linux/seq_file.h> #include <linux/mm.h> -#include <asm/io.h> +#include <linux/io.h> #include "../dev.h" #include "../debug.h" @@ -84,7 +84,7 @@ static int show_channel_command(struct output *o, u32 addr, u32 val, int *count) nvhost_debug_output(o, "GATHER(offset=%03x, insert=%d, type=%d, count=%04x, addr=[", val >> 16 & 0xfff, val >> 15 & 0x1, val >> 14 & 0x1, val & 0x3fff); - *count = val & 0x3fff; // TODO: insert + *count = val & 0x3fff; /* TODO: insert */ return NVHOST_DBG_STATE_GATHER; case 0xe: diff --git a/drivers/video/tegra/host/t20/intr_t20.c b/drivers/video/tegra/host/t20/intr_t20.c index 94bdae4bf392..7df3c1e959e9 100644 --- a/drivers/video/tegra/host/t20/intr_t20.c +++ b/drivers/video/tegra/host/t20/intr_t20.c @@ -183,6 +183,22 @@ static void t20_intr_free_host_general_irq(struct nvhost_intr *intr) } } +static int t20_request_syncpt_irq(struct nvhost_intr_syncpt *syncpt) +{ + int err; + if (syncpt->irq_requested) + return 0; + + err = request_threaded_irq(syncpt->irq, + t20_intr_syncpt_thresh_isr, nvhost_syncpt_thresh_fn, + 0, syncpt->thresh_irq_name, syncpt); + if (err) + return err; + + syncpt->irq_requested = 1; + return 0; +} + int nvhost_init_t20_intr_support(struct nvhost_master *host) { host->op.intr.init_host_sync = t20_intr_init_host_sync; @@ -196,6 +212,8 @@ int nvhost_init_t20_intr_support(struct nvhost_master *host) t20_intr_request_host_general_irq; host->op.intr.free_host_general_irq = t20_intr_free_host_general_irq; + host->op.intr.request_syncpt_irq = + t20_request_syncpt_irq; return 0; } |