Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1689842

Re: [PATCH 1/2] Input: axp20x-pek: add support for AXP221 PEK

From Maxime Ripard <maxime.ripard@free-electrons.com>
Newsgroups linux.kernel
Subject Re: [PATCH 1/2] Input: axp20x-pek: add support for AXP221 PEK
Date 2017-07-18 10:00 +0200
Message-ID <u4vAe-81L-19@gated-at.bofh.it> (permalink)
References <u4aYO-3lP-7@gated-at.bofh.it> <u4aYO-3lP-5@gated-at.bofh.it> <u4cnU-4lE-19@gated-at.bofh.it> <u4vgT-7Vc-29@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

On Tue, Jul 18, 2017 at 09:36:04AM +0200, Quentin Schulz wrote:
> >> +
> >> +	error = sysfs_create_group(&pdev->dev.kobj,
> >> +				   axp20x_pek->attribute_group);
> > 
> > Wouldn't it make more sense to just store the startup_time structure
> > in the axp20x_pek structure, rather than duplicating all this?
> > 
> 
> I don't know. Basically, you would need to recreate manually all the
> structures in the probe function, but why not.

Why?

You have access to axp20x_pek in the readout function. You can just
use the table stored in the structure here, and just ignore any
argument you might have.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 1/2] Input: axp20x-pek: add support for AXP221 PEK Quentin Schulz <quentin.schulz@free-electrons.com> - 2017-07-17 12:00 +0200
  Re: [PATCH 1/2] Input: axp20x-pek: add support for AXP221 PEK Maxime Ripard <maxime.ripard@free-electrons.com> - 2017-07-17 13:30 +0200
    Re: [PATCH 1/2] Input: axp20x-pek: add support for AXP221 PEK Quentin Schulz <quentin.schulz@free-electrons.com> - 2017-07-18 09:40 +0200
      Re: [PATCH 1/2] Input: axp20x-pek: add support for AXP221 PEK Maxime Ripard <maxime.ripard@free-electrons.com> - 2017-07-18 10:00 +0200
        Re: [PATCH 1/2] Input: axp20x-pek: add support for AXP221 PEK Quentin Schulz <quentin.schulz@free-electrons.com> - 2017-07-18 10:20 +0200

csiph-web