public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: Mathieu Poirier <mathieu.poirier@linaro.org>
To: Mike Leach <mike.leach@linaro.org>
Cc: linux-arm-kernel@lists.infradead.org, coresight@lists.linaro.org,
	suzuki.poulose@arm.com, leo.yan@linaro.org
Subject: Re: [PATCH v2 6/6] Documentation: coresight: docs for config load via configfs
Date: Wed, 12 Jan 2022 11:43:20 -0700	[thread overview]
Message-ID: <20220112184320.GB892261@p14s> (raw)
In-Reply-To: <20220112172249.GA892261@p14s>

[...]


> > +
> > +CONFIG_ELEM element
> > +~~~~~~~~~~~~~~~~~~~
> > +
> > +::
> > +
> > +   [cscfg_file_elem_header]                // header length value to end of feature strings.
> > +   [cscfg_file_elem_str]                   // name of the configuration.
> > +   [cscfg_file_elem_str]                   // description of configuration.
> > +   [u16 value](nr_presets)                 // number of defined presets.
> > +   [u32 value](nr_total_params)            // total parameters defined by all used features.
> > +   [u16 value](nr_feat_refs)               // number of features referenced by the configuration
> > +   [u64 values] * (nr_presets * nr_total_params)     // the preset values.
> > +   [cscfg_file_elem_str] * (nr_feat_refs)  // the features used in the configurations.
> 
> There seems to be a discrepency between the above format and the afdo3 structure
> definition in sample file coresight-cfg-filegen.c. 
> 

Void that comment - the above and the struct cscfg_config_desc don't have a 1:1
mapping.

> More comments to come...
> 
> Thanks,
> Mathieu
> 
> > +
> > +FEATURE_ELEM element
> > +~~~~~~~~~~~~~~~~~~~~
> > +
> > +::
> > +
> > +   [cscfg_file_elem_header]                // header length is total bytes to end of param structures.
> > +   [cscfg_file_elem_str]                   // feature name.
> > +   [cscfg_file_elem_str]                   // feature description.
> > +   [u32 value](match_flags)                // flags to associate the feature with a device.
> > +   [u16 value](nr_regs)                    // number of registers.
> > +   [u16 value](nr_params)                  // number of parameters.
> > +   [cscfg_regval_desc struct] * (nr_regs)  // register definitions
> > +   [PARAM_ELEM] * (nr_params)              // parameters definitions
> > +
> > +PARAM_ELEM element
> > +~~~~~~~~~~~~~~~~~~
> > +
> > +::
> > +
> > +   [cscfg_file_elem_str]         // parameter name.
> > +   [u64 value](param_value]      // initial value.
> > +
> > +Additional definitions.
> > +~~~~~~~~~~~~~~~~~~~~~~~
> > +
> > +The following structures are defined in **coresight-config-file.h**
> > +
> > + * **struct cscfg_file_header** : This structure contains an initial magic number, the total
> > +   length of the file, and the number of features in the file.
> > + * **struct cscfg_file_elem_header**: This defines the total length and type of a CONFIG_ELEM
> > +   or a FEATURE_ELEM.
> > + * **struct cscfg_file_elem_str**: This defines a string and its length.
> > +
> > +The magic number in cscfg_file_header is defined as two bitfields::
> > +
> > +   [31:8] Fixed magic number to identify file type.
> > +   [7:0]  Current file format version.
> > +
> > +The following defines determine the maximum overall file size and maximum individual
> > +string size::
> > +
> > +   CSCFG_FILE_MAXSIZE       // maximum overall file size.
> > +   CSCFG_FILE_STR_MAXSIZE   // maximum individual string size.
> > -- 
> > 2.17.1
> > 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2022-01-12 18:44 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-30 22:00 [PATCH v2 0/6] coresight: syscfg: Extend configfs for config load Mike Leach
2021-11-30 22:00 ` [PATCH v2 1/6] coresight: configfs: Add in functionality for load via configfs Mike Leach
2022-01-28 18:08   ` Mathieu Poirier
2022-02-02 20:40     ` Mike Leach
2021-11-30 22:00 ` [PATCH v2 2/6] coresight: configfs: Add in binary attributes to load files Mike Leach
2022-01-28 18:17   ` Mathieu Poirier
2022-02-02 20:33     ` Mike Leach
2022-02-02 22:33       ` Mathieu Poirier
2021-11-30 22:00 ` [PATCH v2 3/6] coresight: configfs: Modify config files to allow userspace use Mike Leach
2022-01-28 18:33   ` Mathieu Poirier
2022-02-02 20:48     ` Mike Leach
2021-11-30 22:00 ` [PATCH v2 4/6] coresight: samples: Add an example config writer for configfs load Mike Leach
2022-01-13 17:56   ` Mathieu Poirier
2022-01-18 16:38     ` Mike Leach
2022-01-28 18:43   ` Mathieu Poirier
2022-02-02 20:54     ` Mike Leach
2021-11-30 22:00 ` [PATCH v2 5/6] coresight: samples: Add coresight file reader sample program Mike Leach
2021-11-30 22:01 ` [PATCH v2 6/6] Documentation: coresight: docs for config load via configfs Mike Leach
2022-01-12 17:22   ` Mathieu Poirier
2022-01-12 18:43     ` Mathieu Poirier [this message]
2022-01-13 18:15   ` Mathieu Poirier
2022-01-18 16:41     ` Mike Leach
2022-01-10 18:58 ` [PATCH v2 0/6] coresight: syscfg: Extend configfs for config load Mathieu Poirier

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=20220112184320.GB892261@p14s \
    --to=mathieu.poirier@linaro.org \
    --cc=coresight@lists.linaro.org \
    --cc=leo.yan@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=mike.leach@linaro.org \
    --cc=suzuki.poulose@arm.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