linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Imran Khan <kimran@codeaurora.org>
Cc: andy.gross@linaro.org, lee.jones@linaro.org,
	David Brown <david.brown@linaro.org>,
	open list <linux-kernel@vger.kernel.org>,
	"open list:ARM/QUALCOMM SUPPORT" <linux-arm-msm@vger.kernel.org>,
	"open list:ARM/QUALCOMM SUPPORT" <linux-soc@vger.kernel.org>
Subject: Re: [PATCH v3] soc: qcom: Add SoC info driver
Date: Mon, 14 Nov 2016 21:27:50 -0800	[thread overview]
Message-ID: <20161115052750.GB28340@tuxbot> (raw)
In-Reply-To: <c0c36a58-c826-84f5-99ed-bb7ee6c5c786@codeaurora.org>

On Mon 14 Nov 06:30 PST 2016, Imran Khan wrote:

> On 11/8/2016 1:05 AM, Bjorn Andersson wrote:
> > On Mon 07 Nov 06:35 PST 2016, Imran Khan wrote:
> > 
> > 
> > 
> > [..]
> > 
> >>>> +static void socinfo_populate(struct soc_device_attribute *soc_dev_attr)
> >>>> +{
> >>>> +	u32 soc_version = socinfo_get_version();
> >>>> +
> >>>> +	soc_dev_attr->soc_id   = kasprintf(GFP_KERNEL, "%d", socinfo_get_id());
> >>>
> >>> I believe soc_id is supposed to be a human readable name; e.g. "MSM8996"
> >>> not "246".
> >>>
> >>
> >> I am not sure about this. I see other vendors also exposing soc_id as numeric value
> >> and machine is perhaps used for a human readable name. Please let me if I 
> >> am getting something wrong here.
> >>
> > 
> > I'm slightly confused to what these various properties are supposed to
> > contain, according to Documentation/ABI/testing/sysfs-devices-soc soc_id
> > should contain the SoC serial number, while most implementations does
> > like you and put something telling which SoC it is.
> > 
> > 246 is however not a useful number, as everyone reading it - be it human
> > or computer - will have to carry the translation table to figure out
> > what it actually says.
> >
> 
> Yeah. I agree on this point. I was just following the lead of other SoCs here.
> Just worried if having a string here breaks the convention. At least having
> a numeric number is more in line with the documentation which expects a 
> serial number. May be here by serial number the documentation means numeric
> id itself. Can someone please provide some feedback? 
>  

Yeah, the more i look at this the more puzzled I become about what
should go where.

> >>>> +	soc_dev_attr->family  =  "Snapdragon";
> > 
> > I think family should be e.g. "MSM8996" and then machine should be e.g.
> > "MSM8996AU".
> > 
> 
> I think here family should be Snapdragon.The following site also mentions
> the SoCs as Snapdragon family of processors.
> 
> https://www.qualcomm.com/products/snapdragon/processors/comparison
> 
> Could you please confirm if it's okay?
> 

In our previous technical discussions regarding Qualcomm platforms the
possible values for "family" would be U, A and B (maybe something new
these days?).

But I don't think we gain anything from having the kernel tell us this.

So I'm fine with you reporting "Snapdragon" as family and I guess
machine would then get e.g. "APQ8096". I don't know what to put in
soc_id.

I think this would be sufficient for user space's needs.

Regards,
Bjorn

  reply	other threads:[~2016-11-15  5:27 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-02 10:06 [PATCH v3] soc: qcom: Add SoC info driver Imran Khan
2016-11-02 18:30 ` Bjorn Andersson
2016-11-07 14:35   ` Imran Khan
2016-11-07 19:35     ` Bjorn Andersson
2016-11-14 14:30       ` Imran Khan
2016-11-15  5:27         ` Bjorn Andersson [this message]
2016-11-16 13:28           ` Imran Khan

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=20161115052750.GB28340@tuxbot \
    --to=bjorn.andersson@linaro.org \
    --cc=andy.gross@linaro.org \
    --cc=david.brown@linaro.org \
    --cc=kimran@codeaurora.org \
    --cc=lee.jones@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-soc@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).