From patchwork Mon Oct 25 02:05:29 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Levitsky X-Patchwork-Id: 266012 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o9P25eMR020373 for ; Mon, 25 Oct 2010 02:05:41 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752799Ab0JYCFj (ORCPT ); Sun, 24 Oct 2010 22:05:39 -0400 Received: from mail-bw0-f46.google.com ([209.85.214.46]:64201 "EHLO mail-bw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752332Ab0JYCFi (ORCPT ); Sun, 24 Oct 2010 22:05:38 -0400 Received: by bwz11 with SMTP id 11so1963681bwz.19 for ; Sun, 24 Oct 2010 19:05:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:date :message-id:x-mailer; bh=9+ypo7vQT3Ljn23MQWFW4EjdLhIhKKGopPsaGtrPv0o=; b=rsGqEt1brSgVuvtSkUknRA1MHeMzB3NwsC0+GZUfOsrhLGdYlQ+LSKza75ItYL3dOv o0v/EOt2soU3a9UCacMQ5kU3mjeCwBbv8uqeE7my0JR/ZPf+oo/cfQCCzDFr6bcv7rNC DsXdliXdIk9YsF9D9Tfnx4MivEs63y5vpEPhU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=N+VjE+ztAOkmqVH/eBd8s+YI1NLenRgUe8nORMf1N+x7xkBVCCS+lGCLWy44KERorf uwVaA/1PGC60sKVuKULn8nsyErZ6mxbgjsxZiNf2SA7UH7Gg3URXq1JBuSzxnsFBApl7 5lwjRzeWnHUJARODqHWFhTSnyjHaz5tf1hr2I= Received: by 10.204.119.80 with SMTP id y16mr3494731bkq.113.1287972337320; Sun, 24 Oct 2010 19:05:37 -0700 (PDT) Received: from maxim-laptop (IGLD-84-228-202-115.inter.net.il [84.228.202.115]) by mx.google.com with ESMTPS id d12sm4361335bkw.19.2010.10.24.19.05.35 (version=SSLv3 cipher=RC4-MD5); Sun, 24 Oct 2010 19:05:36 -0700 (PDT) From: Maxim Levitsky To: lirc-list@lists.sourceforge.net Cc: Jarod Wilson , mchehab@infradead.org, linux-media@vger.kernel.org, Andy Walls , Maxim Levitsky Subject: [PATCH] IR: initialize ir_raw_event in few more drivers Date: Mon, 25 Oct 2010 04:05:29 +0200 Message-Id: <1287972329-8171-1-git-send-email-maximlevitsky@gmail.com> X-Mailer: git-send-email 1.7.1 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Mon, 25 Oct 2010 02:05:41 +0000 (UTC) diff --git a/drivers/media/dvb/siano/smsir.c b/drivers/media/dvb/siano/smsir.c index d0e4639..a27c44a 100644 --- a/drivers/media/dvb/siano/smsir.c +++ b/drivers/media/dvb/siano/smsir.c @@ -40,7 +40,7 @@ void sms_ir_event(struct smscore_device_t *coredev, const char *buf, int len) const s32 *samples = (const void *)buf; for (i = 0; i < len >> 2; i++) { - struct ir_raw_event ev; + DEFINE_IR_RAW_EVENT(ev); ev.duration = abs(samples[i]) * 1000; /* Convert to ns */ ev.pulse = (samples[i] > 0) ? false : true; diff --git a/drivers/media/video/cx23885/cx23888-ir.c b/drivers/media/video/cx23885/cx23888-ir.c index 2502a0a..e78e3e4 100644 --- a/drivers/media/video/cx23885/cx23888-ir.c +++ b/drivers/media/video/cx23885/cx23888-ir.c @@ -704,6 +704,7 @@ static int cx23888_ir_rx_read(struct v4l2_subdev *sd, u8 *buf, size_t count, if (v > IR_MAX_DURATION) v = IR_MAX_DURATION; + init_ir_raw_event(&p->ir_core_data); p->ir_core_data.pulse = u; p->ir_core_data.duration = v; diff --git a/drivers/media/video/cx25840/cx25840-ir.c b/drivers/media/video/cx25840/cx25840-ir.c index c2b4c14..97a4e9b 100644 --- a/drivers/media/video/cx25840/cx25840-ir.c +++ b/drivers/media/video/cx25840/cx25840-ir.c @@ -706,6 +706,7 @@ static int cx25840_ir_rx_read(struct v4l2_subdev *sd, u8 *buf, size_t count, if (v > IR_MAX_DURATION) v = IR_MAX_DURATION; + init_ir_raw_event(&p->ir_core_data); p->ir_core_data.pulse = u; p->ir_core_data.duration = v;