From: Timo Kokkonen <timo.t.kokkonen@iki.fi>
To: Igor Grinberg <grinberg@compulab.co.il>
Cc: linux-omap@vger.kernel.org, linux-media@vger.kernel.org
Subject: Re: [PATCH 2/2] ARM: mach-omap2: board-rx51-peripherals: Add lirc-rx51 data
Date: Thu, 09 Aug 2012 17:09:14 +0300 [thread overview]
Message-ID: <5023C48A.2070509@iki.fi> (raw)
In-Reply-To: <5023B8E9.6040105@compulab.co.il>
On 08/09/12 16:19, Igor Grinberg wrote:
> Hi Timo,
>
> On 08/09/12 15:41, Timo Kokkonen wrote:
>> The IR diode on the RX51 is connected to the GPT9. This data is needed
>> for the IR driver to function.
>>
>> Signed-off-by: Timo Kokkonen <timo.t.kokkonen@iki.fi>
>> ---
>> arch/arm/mach-omap2/board-rx51-peripherals.c | 30 ++++++++++++++++++++++++++
>> 1 files changed, 30 insertions(+), 0 deletions(-)
>>
>> diff --git a/arch/arm/mach-omap2/board-rx51-peripherals.c b/arch/arm/mach-omap2/board-rx51-peripherals.c
>> index df2534d..4a5a71b 100644
>> --- a/arch/arm/mach-omap2/board-rx51-peripherals.c
>> +++ b/arch/arm/mach-omap2/board-rx51-peripherals.c
>> @@ -34,6 +34,7 @@
>> #include <plat/gpmc.h>
>> #include <plat/onenand.h>
>> #include <plat/gpmc-smc91x.h>
>> +#include <plat/omap-pm.h>
>>
>> #include <mach/board-rx51.h>
>>
>> @@ -46,6 +47,10 @@
>> #include <../drivers/staging/iio/light/tsl2563.h>
>> #include <linux/lis3lv02d.h>
>>
>> +#if defined(CONFIG_IR_RX51) || defined(CONFIG_IR_RX51_MODULE)
>> +#include "../../../drivers/media/rc/ir-rx51.h"
>> +#endif
>
> That is not really nice...
> You should place the struct lirc_rx51_platform_data and
> other stuff used outside of the driver in: include/media/
> so you will not have to add that long and ugly relative path.
>
Yeah, you're right. I'll change that. Thanks.
-Timo
>> +
>> #include "mux.h"
>> #include "hsmmc.h"
>> #include "common-board-devices.h"
>> @@ -1220,6 +1225,30 @@ static void __init rx51_init_tsc2005(void)
>> gpio_to_irq(RX51_TSC2005_IRQ_GPIO);
>> }
>>
>> +#if defined(CONFIG_IR_RX51) || defined(CONFIG_IR_RX51_MODULE)
>> +static struct lirc_rx51_platform_data rx51_lirc_data = {
>> + .set_max_mpu_wakeup_lat = omap_pm_set_max_mpu_wakeup_lat,
>> + .pwm_timer = 9, /* Use GPT 9 for CIR */
>> +};
>> +
>> +static struct platform_device rx51_lirc_device = {
>> + .name = "lirc_rx51",
>> + .id = -1,
>> + .dev = {
>> + .platform_data = &rx51_lirc_data,
>> + },
>> +};
>> +
>> +static void __init rx51_init_lirc(void)
>> +{
>> + platform_device_register(&rx51_lirc_device);
>> +}
>> +#else
>> +static void __init rx51_init_lirc(void)
>> +{
>> +}
>> +#endif
>> +
>> void __init rx51_peripherals_init(void)
>> {
>> rx51_i2c_init();
>> @@ -1230,6 +1259,7 @@ void __init rx51_peripherals_init(void)
>> rx51_init_wl1251();
>> rx51_init_tsc2005();
>> rx51_init_si4713();
>> + rx51_init_lirc();
>> spi_register_board_info(rx51_peripherals_spi_board_info,
>> ARRAY_SIZE(rx51_peripherals_spi_board_info));
>>
>
prev parent reply other threads:[~2012-08-09 14:09 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-09 12:41 [PATCH 0/2] Add Nokia N900 (RX51) IR diode support Timo Kokkonen
2012-08-09 12:41 ` [PATCH 1/2] media: rc: Introduce RX51 IR transmitter driver Timo Kokkonen
2012-08-09 13:20 ` Igor Grinberg
2012-08-09 12:41 ` [PATCH 2/2] ARM: mach-omap2: board-rx51-peripherals: Add lirc-rx51 data Timo Kokkonen
2012-08-09 13:19 ` Igor Grinberg
2012-08-09 14:09 ` Timo Kokkonen [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5023C48A.2070509@iki.fi \
--to=timo.t.kokkonen@iki.fi \
--cc=grinberg@compulab.co.il \
--cc=linux-media@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).