linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jarod Wilson <jarod@redhat.com>
To: linux-media@vger.kernel.org
Cc: Jarod Wilson <jarod@redhat.com>
Subject: [PATCH 7/9] [media] mceusb: flash LED (emu v2+ only) to signal end of init
Date: Thu, 14 Jul 2011 18:09:52 -0400	[thread overview]
Message-ID: <1310681394-3530-8-git-send-email-jarod@redhat.com> (raw)
In-Reply-To: <1310681394-3530-1-git-send-email-jarod@redhat.com>

Signed-off-by: Jarod Wilson <jarod@redhat.com>
---
 drivers/media/rc/mceusb.c |   14 ++++++++++++++
 1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/drivers/media/rc/mceusb.c b/drivers/media/rc/mceusb.c
index e4171f7..bbd79c0 100644
--- a/drivers/media/rc/mceusb.c
+++ b/drivers/media/rc/mceusb.c
@@ -452,6 +452,7 @@ static char DEVICE_RESUME[]	= {MCE_CMD_NULL, MCE_CMD_PORT_SYS,
 static char GET_REVISION[]	= {MCE_CMD_PORT_SYS, MCE_CMD_G_REVISION};
 static char GET_EMVER[]		= {MCE_CMD_PORT_SYS, MCE_CMD_GETEMVER};
 static char GET_WAKEVERSION[]	= {MCE_CMD_PORT_SYS, MCE_CMD_GETWAKEVERSION};
+static char FLASH_LED[]		= {MCE_CMD_PORT_SYS, MCE_CMD_FLASHLED};
 static char GET_UNKNOWN2[]	= {MCE_CMD_PORT_IR, MCE_CMD_UNKNOWN2};
 static char GET_CARRIER_FREQ[]	= {MCE_CMD_PORT_IR, MCE_CMD_GETIRCFS};
 static char GET_RX_TIMEOUT[]	= {MCE_CMD_PORT_IR, MCE_CMD_GETIRTIMEOUT};
@@ -592,6 +593,9 @@ static void mceusb_dev_printdata(struct mceusb_dev *ir, char *buf,
 				dev_info(dev, "TX port %d: blaster is%s connected\n",
 					 data1 + 1, data4 ? " not" : "");
 			break;
+		case MCE_CMD_FLASHLED:
+			dev_info(dev, "Attempting to flash LED\n");
+			break;
 		default:
 			dev_info(dev, "Unknown command 0x%02x 0x%02x\n",
 				 cmd, subcmd);
@@ -1166,6 +1170,14 @@ static void mceusb_get_parameters(struct mceusb_dev *ir)
 	}
 }
 
+static void mceusb_flash_led(struct mceusb_dev *ir)
+{
+	if (ir->emver < 2)
+		return;
+
+	mce_async_out(ir, FLASH_LED, sizeof(FLASH_LED));
+}
+
 static struct rc_dev *mceusb_init_rc_dev(struct mceusb_dev *ir)
 {
 	struct device *dev = ir->dev;
@@ -1343,6 +1355,8 @@ static int __devinit mceusb_dev_probe(struct usb_interface *intf,
 
 	mceusb_get_parameters(ir);
 
+	mceusb_flash_led(ir);
+
 	if (ir->num_txports && !ir->flags.no_tx) {
 		ir->rc->s_tx_mask = mceusb_set_tx_mask;
 		ir->rc->s_tx_carrier = mceusb_set_tx_carrier;
-- 
1.7.1


  parent reply	other threads:[~2011-07-14 22:10 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-14 22:09 [PATCH 0/9] mceusb updates per MS docs Jarod Wilson
2011-07-14 22:09 ` [PATCH 1/9] [media] mceusb: command/response updates from " Jarod Wilson
2011-07-14 22:09 ` [PATCH 2/9] [media] mceusb: give hardware time to reply to cmds Jarod Wilson
2011-07-14 23:30   ` Mauro Carvalho Chehab
2011-07-18 17:47     ` Jarod Wilson
2011-07-18 18:11       ` Jarod Wilson
2011-07-14 22:09 ` [PATCH 3/9] [media] mceusb: set wakeup bits for IR-based resume Jarod Wilson
2011-07-14 22:09 ` [PATCH 4/9] [media] mceusb: issue device resume cmd when needed Jarod Wilson
2011-07-14 22:09 ` [PATCH 5/9] [media] mceusb: query device for firmware emulator version Jarod Wilson
2011-07-14 22:09 ` [PATCH 6/9] [media] mceusb: get misc port data from hardware Jarod Wilson
2011-07-14 22:09 ` Jarod Wilson [this message]
2011-07-14 22:09 ` [PATCH 8/9] [media] mceusb: report actual tx frequencies Jarod Wilson
2011-07-14 22:09 ` [PATCH 9/9] [media] mceusb: update version, copyright, author Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 0/9] mceusb updates per MS docs Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 1/9] [media] mceusb: command/response updates from " Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 2/9] [media] mceusb: give hardware time to reply to cmds Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 3/9] [media] mceusb: set wakeup bits for IR-based resume Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 4/9] [media] mceusb: issue device resume cmd when needed Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 5/9] [media] mceusb: query device for firmware emulator version Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 6/9] [media] mceusb: get misc port data from hardware Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 7/9] [media] mceusb: flash LED (emu v2+ only) to signal end of init Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 8/9] [media] mceusb: report actual tx frequencies Jarod Wilson
2011-07-18 19:54 ` [PATCH v2 9/9] [media] mceusb: update version, copyright, author Jarod Wilson

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=1310681394-3530-8-git-send-email-jarod@redhat.com \
    --to=jarod@redhat.com \
    --cc=linux-media@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).