linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sean Young <sean@mess.org>
To: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Cc: Jarod Wilson <jarod@redhat.com>, linux-media@vger.kernel.org
Subject: Re: [PATCH] [media] nec decoder: wrong bit order for nec32 protocol
Date: Tue, 22 Nov 2016 15:56:26 +0000	[thread overview]
Message-ID: <20161122155626.GB11405@gofer.mess.org> (raw)
In-Reply-To: <20161122130852.6f8d259f@vento.lan>

On Tue, Nov 22, 2016 at 01:08:52PM -0200, Mauro Carvalho Chehab wrote:
> Em Tue, 22 Nov 2016 09:19:19 -0500
> Jarod Wilson <jarod@redhat.com> escreveu:
> > Been away from the game for a few years now, so there are a good number of
> > cobwebs in this section of my brain... I'm pretty sure I do have both a
> > remote and receiver on hand that would fit the bill here though. Is the
> > question primarily about what actually gets emitted by the TiVo remote?
> 
> Yes. Sean suspects that we're decoding the NEC 32 bits in the
> wrong order at the in-kernel NEC decoder on x86[1].
> 
> The idea here is to double-check how the bits are encapsulated, in order
> to do the right thing at the IR decoder.
> 
> [1] the current code actually sucks, as it produces different
> scancodes on big endian or little endian, so it needs to be
> fixed anyway, as it simply does:
> 	scancode = data->bits;
> 
> instead of using be32_to_cpu().

Bits are shifted in one at at time in the nec decoder so it is endian safe.

The problem is that the same NEC32 IR will produce different scancodes
with ir-nec-decoder.c and other nec decoders, e.g. dib0700_core.c


Sean

  reply	other threads:[~2016-11-22 15:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-09 16:13 [PATCH] [media] nec decoder: wrong bit order for nec32 protocol Sean Young
2016-11-22 13:35 ` Mauro Carvalho Chehab
2016-11-22 14:19   ` Jarod Wilson
2016-11-22 15:08     ` Mauro Carvalho Chehab
2016-11-22 15:56       ` Sean Young [this message]
2016-11-22 15:49     ` Sean Young

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=20161122155626.GB11405@gofer.mess.org \
    --to=sean@mess.org \
    --cc=jarod@redhat.com \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@s-opensource.com \
    /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).