Wireless-regdb Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [wireless-regdb] CAC time syntax in regdb.txt
@ 2015-03-26 17:19 Jean-Pierre TOSONI
  2015-03-26 19:25 ` Seth Forshee
  0 siblings, 1 reply; 7+ messages in thread
From: Jean-Pierre TOSONI @ 2015-03-26 17:19 UTC (permalink / raw)
  To: wireless-regdb

Hi list,

I saw that the library in crda was updated to handle the CAC time.
AFAICT the format is
      (freq - freq @ bw), (eirp [mW]), [(CACtime)] [flags...]

but the conversion of the database from text format to bin format is
still using a python script that crashes with this format.
I used the
https://git.kernel.org/cgit/linux/kernel/git/sforshee/wireless-regdb.git
repo.

Is there an updated python script out there? Or a replacement tool? Or
am I missing a something?

Thanks

Jean-Pierre Tosoni

_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [wireless-regdb] CAC time syntax in regdb.txt
  2015-03-26 17:19 [wireless-regdb] CAC time syntax in regdb.txt Jean-Pierre TOSONI
@ 2015-03-26 19:25 ` Seth Forshee
  2015-03-26 20:42   ` Luis R. Rodriguez
  0 siblings, 1 reply; 7+ messages in thread
From: Seth Forshee @ 2015-03-26 19:25 UTC (permalink / raw)
  To: Jean-Pierre TOSONI, Luis R. Rodriguez; +Cc: wireless-regdb

On Thu, Mar 26, 2015 at 06:19:02PM +0100, Jean-Pierre TOSONI wrote:
> Hi list,
> 
> I saw that the library in crda was updated to handle the CAC time.
> AFAICT the format is
>       (freq - freq @ bw), (eirp [mW]), [(CACtime)] [flags...]
> 
> but the conversion of the database from text format to bin format is
> still using a python script that crashes with this format.
> I used the
> https://git.kernel.org/cgit/linux/kernel/git/sforshee/wireless-regdb.git
> repo.
> 
> Is there an updated python script out there? Or a replacement tool? Or
> am I missing a something?

CRDA was updated to understand db.txt files with DFS CAC times, but the
binary format doesn't include them. The best that could be done then is
to make dbparse.py ignore CAC times. But the only purpose for the python
scripts is to convert wireless-regdb's db.txt to binary format, and it
would be a bit misleading to include CAC times in db.txt if they can't
be included in regulatory.bin. So I don't really see much of a point in
updating dbparse.py until the binary format supports CAC times.

Luis - Any thoughts? Are there plans to add DFS CAC times to the binary
format?

Seth

_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [wireless-regdb] CAC time syntax in regdb.txt
  2015-03-26 19:25 ` Seth Forshee
@ 2015-03-26 20:42   ` Luis R. Rodriguez
  2015-03-30  8:03     ` Johannes Berg
  0 siblings, 1 reply; 7+ messages in thread
From: Luis R. Rodriguez @ 2015-03-26 20:42 UTC (permalink / raw)
  To: Seth Forshee; +Cc: Jean-Pierre TOSONI, wireless-regdb, Luis R. Rodriguez

On Thu, Mar 26, 2015 at 02:25:32PM -0500, Seth Forshee wrote:
> On Thu, Mar 26, 2015 at 06:19:02PM +0100, Jean-Pierre TOSONI wrote:
> > Hi list,
> > 
> > I saw that the library in crda was updated to handle the CAC time.
> > AFAICT the format is
> >       (freq - freq @ bw), (eirp [mW]), [(CACtime)] [flags...]
> > 
> > but the conversion of the database from text format to bin format is
> > still using a python script that crashes with this format.
> > I used the
> > https://git.kernel.org/cgit/linux/kernel/git/sforshee/wireless-regdb.git
> > repo.
> > 
> > Is there an updated python script out there? Or a replacement tool? Or
> > am I missing a something?
> 
> CRDA was updated to understand db.txt files with DFS CAC times, but the
> binary format doesn't include them. The best that could be done then is
> to make dbparse.py ignore CAC times. But the only purpose for the python
> scripts is to convert wireless-regdb's db.txt to binary format, and it
> would be a bit misleading to include CAC times in db.txt if they can't
> be included in regulatory.bin. So I don't really see much of a point in
> updating dbparse.py until the binary format supports CAC times.
> 
> Luis - Any thoughts? Are there plans to add DFS CAC times to the binary
> format?

This would require generating two binary files and supporting that.  This was
never done. We could also try to somehow mesh both versions together with one
larger file that has both and try to remain compatible. That's the ideal
solution IMHO.

Instead of sticking to CRDA updates to rely on this for support what we really
need to do is mesh in CRDA support upstream into the kernel since the kernel
now supports the cryptographic needs that CRDA had. I was planning on doing
this during the upcoming Hackweek at SUSE but if anyone else wants to try that
before please feel free.

We should address both of these. In the meantime if folks want CAC support it
seems the internal regdb form supports it. An awk script is used currently
in-kernel to generate the binary file, that awk script is obviously fragile,
its yet-another reason to move away from it and instead have the binary parser
in-kernel as we do within CRDA. The work required to mesh CRDA support into the
kernel is to generalize the cryptographic needs of a file request into
request_file_req(), adding a requirements structure which defines the
requirements for the file, then aliasing request_firmware() to use this API
where the req is NULL, request_file() instead of request_firmware() would be
used by the regulatory core to request the regulatory file, and if
cryptographic support was added that would be passed as a requirement.

Since most of the code for parsing the binary file is already in place in
CRDA that would just need to be tossed into the kernel and kernel'afied.

That's all.

 Luis

_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [wireless-regdb] CAC time syntax in regdb.txt
  2015-03-26 20:42   ` Luis R. Rodriguez
@ 2015-03-30  8:03     ` Johannes Berg
  2015-03-30 21:10       ` Luis R. Rodriguez
  0 siblings, 1 reply; 7+ messages in thread
From: Johannes Berg @ 2015-03-30  8:03 UTC (permalink / raw)
  To: Luis R. Rodriguez
  Cc: Seth Forshee, Luis R. Rodriguez, wireless-regdb,
	Jean-Pierre TOSONI

On Thu, 2015-03-26 at 21:42 +0100, Luis R. Rodriguez wrote:

> This would require generating two binary files and supporting that.  This was
> never done. We could also try to somehow mesh both versions together with one
> larger file that has both and try to remain compatible. That's the ideal
> solution IMHO.

Given the file format, I don't think this will be possible.

> Instead of sticking to CRDA updates to rely on this for support what we really
> need to do is mesh in CRDA support upstream into the kernel since the kernel
> now supports the cryptographic needs that CRDA had. I was planning on doing
> this during the upcoming Hackweek at SUSE but if anyone else wants to try that
> before please feel free.

And given that we want this direction anyway, I'm not sure that the
multi-file-format CRDA solution will really be economical.

For the kernel, we should probably define an extensible file format
anyway, and then just do it once.

johannes


_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [wireless-regdb] CAC time syntax in regdb.txt
  2015-03-30  8:03     ` Johannes Berg
@ 2015-03-30 21:10       ` Luis R. Rodriguez
  2015-04-03  5:26         ` Janusz Dziedzic
  0 siblings, 1 reply; 7+ messages in thread
From: Luis R. Rodriguez @ 2015-03-30 21:10 UTC (permalink / raw)
  To: Johannes Berg
  Cc: Seth Forshee, Luis R. Rodriguez, wireless-regdb,
	Jean-Pierre TOSONI

On Mon, Mar 30, 2015 at 10:03:34AM +0200, Johannes Berg wrote:
> On Thu, 2015-03-26 at 21:42 +0100, Luis R. Rodriguez wrote:
> 
> > This would require generating two binary files and supporting that.  This was
> > never done. We could also try to somehow mesh both versions together with one
> > larger file that has both and try to remain compatible. That's the ideal
> > solution IMHO.
> 
> Given the file format, I don't think this will be possible.
> 
> > Instead of sticking to CRDA updates to rely on this for support what we really
> > need to do is mesh in CRDA support upstream into the kernel since the kernel
> > now supports the cryptographic needs that CRDA had. I was planning on doing
> > this during the upcoming Hackweek at SUSE but if anyone else wants to try that
> > before please feel free.
> 
> And given that we want this direction anyway, I'm not sure that the
> multi-file-format CRDA solution will really be economical.
> 
> For the kernel, we should probably define an extensible file format
> anyway, and then just do it once.

Ack. I can try to address both then during Hackweek unless someone wants
to jump on it sooner.

 Luis

_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [wireless-regdb] CAC time syntax in regdb.txt
  2015-03-30 21:10       ` Luis R. Rodriguez
@ 2015-04-03  5:26         ` Janusz Dziedzic
  2015-04-07  7:35           ` Jean-Pierre Tosoni
  0 siblings, 1 reply; 7+ messages in thread
From: Janusz Dziedzic @ 2015-04-03  5:26 UTC (permalink / raw)
  To: Luis R. Rodriguez
  Cc: Jean-Pierre TOSONI, Seth Forshee, Johannes Berg,
	wireless-regdb@lists.infradead.org, Luis R. Rodriguez

On 30 March 2015 at 23:10, Luis R. Rodriguez <mcgrof@suse.com> wrote:
> On Mon, Mar 30, 2015 at 10:03:34AM +0200, Johannes Berg wrote:
>> On Thu, 2015-03-26 at 21:42 +0100, Luis R. Rodriguez wrote:
>>
>> > This would require generating two binary files and supporting that.  This was
>> > never done. We could also try to somehow mesh both versions together with one
>> > larger file that has both and try to remain compatible. That's the ideal
>> > solution IMHO.
>>
>> Given the file format, I don't think this will be possible.
>>
>> > Instead of sticking to CRDA updates to rely on this for support what we really
>> > need to do is mesh in CRDA support upstream into the kernel since the kernel
>> > now supports the cryptographic needs that CRDA had. I was planning on doing
>> > this during the upcoming Hackweek at SUSE but if anyone else wants to try that
>> > before please feel free.
>>
>> And given that we want this direction anyway, I'm not sure that the
>> multi-file-format CRDA solution will really be economical.
>>
>> For the kernel, we should probably define an extensible file format
>> anyway, and then just do it once.
>
> Ack. I can try to address both then during Hackweek unless someone wants
> to jump on it sooner.
>

Hello Jean-Pierre,

Before this will be ready, you can always chek crda-tiny
implementation, where signed db.txt file is used (skiped bin file) -
and CAC time works fine.
So, you can check this patch: [RFC 2/2] crda: add crda_tiny implementation .

BR
Janusz

_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [wireless-regdb] CAC time syntax in regdb.txt
  2015-04-03  5:26         ` Janusz Dziedzic
@ 2015-04-07  7:35           ` Jean-Pierre Tosoni
  0 siblings, 0 replies; 7+ messages in thread
From: Jean-Pierre Tosoni @ 2015-04-07  7:35 UTC (permalink / raw)
  To: 'Janusz Dziedzic'; +Cc: wireless-regdb

Thanks Janusz, I will have a look at that.

-----Message d'origine-----
De : wireless-regdb [mailto:wireless-regdb-bounces@lists.infradead.org] De
la part de Janusz Dziedzic
Envoyé : vendredi 3 avril 2015 07:27
À : Luis R. Rodriguez
Cc : Jean-Pierre TOSONI; Seth Forshee; Johannes Berg;
wireless-regdb@lists.infradead.org; Luis R. Rodriguez
Objet : Re: [wireless-regdb] CAC time syntax in regdb.txt

On 30 March 2015 at 23:10, Luis R. Rodriguez <mcgrof@suse.com> wrote:
> On Mon, Mar 30, 2015 at 10:03:34AM +0200, Johannes Berg wrote:
>> On Thu, 2015-03-26 at 21:42 +0100, Luis R. Rodriguez wrote:
>>
>> > This would require generating two binary files and supporting that.  
>> > This was never done. We could also try to somehow mesh both 
>> > versions together with one larger file that has both and try to 
>> > remain compatible. That's the ideal solution IMHO.
>>
>> Given the file format, I don't think this will be possible.
>>
>> > Instead of sticking to CRDA updates to rely on this for support 
>> > what we really need to do is mesh in CRDA support upstream into the 
>> > kernel since the kernel now supports the cryptographic needs that 
>> > CRDA had. I was planning on doing this during the upcoming Hackweek 
>> > at SUSE but if anyone else wants to try that before please feel free.
>>
>> And given that we want this direction anyway, I'm not sure that the 
>> multi-file-format CRDA solution will really be economical.
>>
>> For the kernel, we should probably define an extensible file format 
>> anyway, and then just do it once.
>
> Ack. I can try to address both then during Hackweek unless someone 
> wants to jump on it sooner.
>

Hello Jean-Pierre,

Before this will be ready, you can always chek crda-tiny implementation,
where signed db.txt file is used (skiped bin file) - and CAC time works
fine.
So, you can check this patch: [RFC 2/2] crda: add crda_tiny implementation .

BR
Janusz

_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


_______________________________________________
wireless-regdb mailing list
wireless-regdb@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/wireless-regdb


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-04-07  9:44 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-26 17:19 [wireless-regdb] CAC time syntax in regdb.txt Jean-Pierre TOSONI
2015-03-26 19:25 ` Seth Forshee
2015-03-26 20:42   ` Luis R. Rodriguez
2015-03-30  8:03     ` Johannes Berg
2015-03-30 21:10       ` Luis R. Rodriguez
2015-04-03  5:26         ` Janusz Dziedzic
2015-04-07  7:35           ` Jean-Pierre Tosoni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox