Linux bluetooth development
 help / color / mirror / Atom feed
From: Paul Menzel <paulepanter@users.sourceforge.net>
To: pulseaudio-discuss@mail.0pointer.de
Cc: Siarhei Siamashka <siarhei.siamashka@nokia.com>,
	linux-bluetooth@vger.kernel.org
Subject: Re: [pulseaudio-discuss] [PATCH] sbc_math.h: add explicit check for ARMv6 instructions
Date: Tue, 29 Mar 2011 01:00:57 +0200	[thread overview]
Message-ID: <1301353257.6649.6.camel@mattotaupa> (raw)
In-Reply-To: <AANLkTi=wTkJ654Zo0SEuzLi3MBjvee54HvToxmeYGMF1@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 6771 bytes --]

Dear BlueZ folks,


Am Montag, den 28.03.2011, 18:41 +0300 schrieb Luiz Augusto von Dentz:

> On Fri, Mar 25, 2011 at 1:34 PM, Paul Menzel wrote:

> > Am Samstag, den 19.03.2011, 16:14 +0530 schrieb Arun Raghavan:
> >
> >> On Wed, 2011-02-23 at 01:07 +0530, Arun Raghavan wrote:
> >> [...]
> >> > The correct fix for this, imo, is in bluez (there is a new
> >> > sbc_primitives_armv6.h that can probably be used at least as a
> >> > template). We need to do an sbc-udpate on the PA side anyway, and can
> >> > pull this when we do.
> >>
> >> Could you see if the attached patch works for you? If it does, I can
> >> push this to the bluez folks.
> >
> > My tag on the other thread [1] is ambiguous. The error is indeed caused
> > by your patch. I will try to implement your recommended changes but will
> > probably not get to it before Sunday.
> 
> Im including Siarhei Siamashka since he did most, if not all, of this
> code and linux-bluetooth to cc.

to fix [1] I tried to add `#include "sbc_tables.h"` to
`src/modules/bluetooth/sbc/sbc_primitives.h`

        diff --git a/src/modules/bluetooth/sbc/sbc_primitives.h b/src/modules/bluetooth/
        index 3fec8d5..9544826 100644
        --- a/src/modules/bluetooth/sbc/sbc_primitives.h
        +++ b/src/modules/bluetooth/sbc/sbc_primitives.h
        @@ -24,6 +24,8 @@
          *
          */
         
        +#include "sbc_tables.h"
        +
         #ifndef __SBC_PRIMITIVES_H
         #define __SBC_PRIMITIVES_H

But this seems to result in a need for `sbc_math.h` which leads to a
circular inclusion.

        […]
        In file included from modules/bluetooth/sbc/sbc_primitives.h:27:0,
                         from modules/bluetooth/sbc/sbc_primitives_armv6.h:30,
                         from modules/bluetooth/sbc/sbc_math.h:27,
                         from modules/bluetooth/sbc/sbc.c:46:
        modules/bluetooth/sbc/sbc_tables.h:50:2: warning: implicit declaration of function 'ASR' [-Wimplicit-function-declaration]
        modules/bluetooth/sbc/sbc_tables.h:50:2: error: 'SCALE_SPROTO4_TBL' undeclared here (not in a function)
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: (near initialization for 'sbc_proto_4_40m1[0]')
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: (near initialization for 'sbc_proto_4_40m1[1]')
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: (near initialization for 'sbc_proto_4_40m1[2]')
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:58:2: error: (near initialization for 'sbc_proto_4_40m1[3]')
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: (near initialization for 'sbc_proto_4_40m1[4]')
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: (near initialization for 'sbc_proto_4_40m1[5]')
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: (near initialization for 'sbc_proto_4_40m1[6]')
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:59:2: error: (near initialization for 'sbc_proto_4_40m1[7]')
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: (near initialization for 'sbc_proto_4_40m1[8]')
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: (near initialization for 'sbc_proto_4_40m1[9]')
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: (near initialization for 'sbc_proto_4_40m1[10]')
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:60:2: error: (near initialization for 'sbc_proto_4_40m1[11]')
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: (near initialization for 'sbc_proto_4_40m1[12]')
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: (near initialization for 'sbc_proto_4_40m1[13]')
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: (near initialization for 'sbc_proto_4_40m1[14]')
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:61:2: error: (near initialization for 'sbc_proto_4_40m1[15]')
        modules/bluetooth/sbc/sbc_tables.h:62:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:62:2: error: (near initialization for 'sbc_proto_4_40m1[16]')
        modules/bluetooth/sbc/sbc_tables.h:62:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:62:2: error: (near initialization for 'sbc_proto_4_40m1[17]')
        modules/bluetooth/sbc/sbc_tables.h:62:2: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:62:2: error: (near initialization for 'sbc_proto_4_40m1[18]')
        modules/bluetooth/sbc/sbc_tables.h:63:1: error: initializer element is not constant
        modules/bluetooth/sbc/sbc_tables.h:63:1: error: (near initialization for 'sbc_proto_4_40m1[19]')
        [ goes on … ]

> Btw, the sbc subdir should be in sync with sbc subdir in BlueZ tree.

The question is how often should the updates be made. As far as I know
`make update-sbc` is only run once in a while.

        commit b676f89d8579c7ec1629892342a330f1e4c35657
        Author: Colin Guthrie <cguthrie@mandriva.org>
        Date:   Sun Mar 20 11:44:53 2011 +0000
        
            bluetooth: Run 'make update-sbc'
            
            Note that changes to ipc.h from 8f3ef04b had to be manually reapplied.


Thanks,

Paul


[1] https://tango.0pointer.de/pipermail/pulseaudio-discuss/2011-March/009594.html

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  parent reply	other threads:[~2011-03-28 23:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1298226004.3712.1.camel@mattotaupa>
     [not found] ` <1298320304.6159.21.camel@snowflake>
     [not found]   ` <ik00pv$8d8$1@dough.gmane.org>
     [not found]     ` <1298374409.3861.32.camel@mattotaupa>
     [not found]       ` <1298403438.6736.26.camel@snowflake>
     [not found]         ` <1300531488.6875.3.camel@snowflake>
     [not found]           ` <1301052849.7592.15.camel@mattotaupa>
2011-03-28 15:41             ` [pulseaudio-discuss] [PATCH] sbc_math.h: add explicit check for ARMv6 instructions Luiz Augusto von Dentz
2011-03-28 16:42               ` Siarhei Siamashka
2011-03-28 23:00               ` Paul Menzel [this message]
2011-03-29 10:21                 ` Colin Guthrie
2011-03-30 17:42                   ` Luiz Augusto von Dentz

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=1301353257.6649.6.camel@mattotaupa \
    --to=paulepanter@users.sourceforge.net \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=pulseaudio-discuss@mail.0pointer.de \
    --cc=siarhei.siamashka@nokia.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