linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sean Young <sean@mess.org>
To: Philip Downer <pdowner@prospero-tech.com>
Cc: linux-media@vger.kernel.org
Subject: Re: [RFC PATCH 1/1] [media] pci: Add support for DVB PCIe cards from Prospero Technologies Ltd.
Date: Thu, 19 Feb 2015 12:40:37 +0000	[thread overview]
Message-ID: <20150219124037.GA3500@gofer.mess.org> (raw)
In-Reply-To: <1424116126-14052-2-git-send-email-pdowner@prospero-tech.com>

On Mon, Feb 16, 2015 at 07:48:46PM +0000, Philip Downer wrote:
-snip-
> +	dev = rc_allocate_device();
> +
> +	if (!ir || !dev)
> +		goto err_out_free;
> +
> +	ir->dev = dev;
> +
> +	snprintf(ir->name, sizeof(ir->name), "prospero IR");
> +	snprintf(ir->phys, sizeof(ir->phys), "pci-%s/ir0", pci_name(pci));
> +
> +	dev->input_name = ir->name;
> +	dev->input_phys = ir->phys;
> +	dev->input_id.bustype = BUS_PCI;
> +	dev->input_id.version = 1;
> +	dev->input_id.vendor = pci->vendor;
> +	dev->input_id.product = pci->device;
> +
> +	dev->dev.parent = &pci->dev;
> +	dev->map_name = RC_MAP_LIRC;

RC_MAP_LIRC isn't really a useful default; no remote will work with that.
Other drivers default to RC_MAP_RC6_MCE if no remote was provided with 
the product. I don't know if this is good choice, but at least it is
consistent.

> +
> +	dev->driver_name = "prospero";
> +	dev->priv = p;
> +	dev->open = prospero_ir_open;
> +	dev->close = prospero_ir_close;
> +	dev->driver_type = RC_DRIVER_IR_RAW;
> +	dev->timeout = 10 * 1000 * 1000;

There is a MS_TO_NS() macro for this.


Sean

  parent reply	other threads:[~2015-02-19 12:40 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-16 19:48 [RFC PATCH 0/1] [media] pci: Add support for DVB PCIe cards from Prospero Technologies Ltd Philip Downer
2015-02-16 19:48 ` [RFC PATCH 1/1] " Philip Downer
2015-02-19 11:06   ` Sean Young
2015-02-19 12:22     ` Philip Downer
2015-02-19 12:40   ` Sean Young [this message]
2015-02-19 16:05     ` Philip Downer
2015-02-16 20:01 ` [RFC PATCH 0/1] " Antti Palosaari
2015-02-16 20:46   ` Philip Downer
2015-02-16 23:47   ` Mauro Carvalho Chehab
2015-02-17 18:22     ` Philip Downer
2015-02-17 19:14       ` Antti Palosaari
2015-02-18 11:07         ` Philip Downer

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=20150219124037.GA3500@gofer.mess.org \
    --to=sean@mess.org \
    --cc=linux-media@vger.kernel.org \
    --cc=pdowner@prospero-tech.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).