Marcel Holtmann | 1 Nov 15:30 2009

Re: [PATCH] Inserted the GSM syntax option in modem.conf. (Revised).

Hi Ryan,

> This is patch to allow the gsm syntax to be specified in the
> modem.conf file. It is a 2nd version based on code change requests.

patch has been applied. Thanks.

Regards

Marcel

Zhenhua Zhang | 3 Nov 18:46 2009
Picon

Re: [PATCH 1/1] Create network registration driver for hfpmodem

Hi Padovan,

Gustavo F. Padovan wrote:
> This driver handles phone informations about registration status, signal
> strength and roaming status listening +CIEV commands.  It also gets the
> Network Operator name with +COPS commands.
> ---
>  Makefile.am                             |    3 +-
>  drivers/hfpmodem/hfpmodem.c             |    2 +
>  drivers/hfpmodem/hfpmodem.h             |    3 +
>  drivers/hfpmodem/network-registration.c |  365 +++++++++++++++++++++++++++++++
>  plugins/hfp.c                           |    1 +
>  5 files changed, 373 insertions(+), 1 deletions(-)
>  create mode 100644 drivers/hfpmodem/network-registration.c

On compiling your code I got:

  CC     drivers/hfpmodem/network-registration.o
cc1: warnings being treated as errors
drivers/hfpmodem/network-registration.c: In function ‘cops_cb’:
drivers/hfpmodem/network-registration.c:101: error: label ‘error’
defined but not used
drivers/hfpmodem/network-registration.c:58: error: unused variable ‘nd’
make[1]: *** [drivers/hfpmodem/network-registration.o] Error 1
make: *** [all] Error 2

So I have below patch to remove 'nd' and refine labels in cops_cb.
Please review it.

I would suggest to replace 'out' label by return. We really don't need
(Continue reading)

Gustavo F. Padovan | 3 Nov 17:53 2009

Re: [PATCH 1/1] Create network registration driver for hfpmodem

Hi Zhenhua,

On Tue, Nov 3, 2009 at 3:46 PM, Zhenhua Zhang <zhenhua.zhang <at> intel.com> wrote:
> Hi Padovan,
>
> Gustavo F. Padovan wrote:
>> This driver handles phone informations about registration status, signal
>> strength and roaming status listening +CIEV commands.  It also gets the
>> Network Operator name with +COPS commands.
>> ---
>>  Makefile.am                             |    3 +-
>>  drivers/hfpmodem/hfpmodem.c             |    2 +
>>  drivers/hfpmodem/hfpmodem.h             |    3 +
>>  drivers/hfpmodem/network-registration.c |  365 +++++++++++++++++++++++++++++++
>>  plugins/hfp.c                           |    1 +
>>  5 files changed, 373 insertions(+), 1 deletions(-)
>>  create mode 100644 drivers/hfpmodem/network-registration.c
>
> On compiling your code I got:
>
>  CC     drivers/hfpmodem/network-registration.o
> cc1: warnings being treated as errors
> drivers/hfpmodem/network-registration.c: In function ‘cops_cb’:
> drivers/hfpmodem/network-registration.c:101: error: label ‘error’
> defined but not used
> drivers/hfpmodem/network-registration.c:58: error: unused variable ‘nd’
> make[1]: *** [drivers/hfpmodem/network-registration.o] Error 1
> make: *** [all] Error 2

Sorry, I forgot the --enable-maintainer-mode. :(
(Continue reading)

Gustavo F. Padovan | 3 Nov 18:04 2009

[PATCH 1/1] Create network registration driver for hfpmodem

This driver handles phone informations about registration status, signal
strength and roaming status listening +CIEV commands.  It also gets the
Network Operator name with +COPS commands.
---
 Makefile.am                             |    3 +-
 drivers/hfpmodem/hfpmodem.c             |    2 +
 drivers/hfpmodem/hfpmodem.h             |    3 +
 drivers/hfpmodem/network-registration.c |  365 +++++++++++++++++++++++++++++++
 plugins/hfp.c                           |    1 +
 5 files changed, 373 insertions(+), 1 deletions(-)
 create mode 100644 drivers/hfpmodem/network-registration.c

diff --git a/Makefile.am b/Makefile.am
index 8e56568..c3e06b4 100644
--- a/Makefile.am
+++ b/Makefile.am
 <at>  <at>  -126,7 +126,8  <at>  <at>  builtin_modules += hfpmodem
 builtin_sources += drivers/atmodem/atutil.h \
 			drivers/hfpmodem/hfpmodem.h \
 			drivers/hfpmodem/hfpmodem.c \
-			drivers/hfpmodem/voicecall.c
+			drivers/hfpmodem/voicecall.c \
+			drivers/hfpmodem/network-registration.c

 builtin_modules += mbmmodem
 builtin_sources += drivers/atmodem/atutil.h \
diff --git a/drivers/hfpmodem/hfpmodem.c b/drivers/hfpmodem/hfpmodem.c
index 03b5ea0..58ae03d 100644
--- a/drivers/hfpmodem/hfpmodem.c
+++ b/drivers/hfpmodem/hfpmodem.c
(Continue reading)

Gustavo F. Padovan | 3 Nov 18:44 2009

[PATCH 1/1] Create network registration driver for hfpmodem

This driver handles phone informations about registration status, signal
strength and roaming status listening +CIEV commands.  It also gets the
Network Operator name with +COPS commands.
---
 Makefile.am                             |    3 +-
 drivers/hfpmodem/hfpmodem.c             |    2 +
 drivers/hfpmodem/hfpmodem.h             |    3 +
 drivers/hfpmodem/network-registration.c |  356 +++++++++++++++++++++++++++++++
 plugins/hfp.c                           |    1 +
 5 files changed, 364 insertions(+), 1 deletions(-)
 create mode 100644 drivers/hfpmodem/network-registration.c

diff --git a/Makefile.am b/Makefile.am
index 8e56568..c3e06b4 100644
--- a/Makefile.am
+++ b/Makefile.am
 <at>  <at>  -126,7 +126,8  <at>  <at>  builtin_modules += hfpmodem
 builtin_sources += drivers/atmodem/atutil.h \
 			drivers/hfpmodem/hfpmodem.h \
 			drivers/hfpmodem/hfpmodem.c \
-			drivers/hfpmodem/voicecall.c
+			drivers/hfpmodem/voicecall.c \
+			drivers/hfpmodem/network-registration.c

 builtin_modules += mbmmodem
 builtin_sources += drivers/atmodem/atutil.h \
diff --git a/drivers/hfpmodem/hfpmodem.c b/drivers/hfpmodem/hfpmodem.c
index 03b5ea0..58ae03d 100644
--- a/drivers/hfpmodem/hfpmodem.c
+++ b/drivers/hfpmodem/hfpmodem.c
(Continue reading)

Martin Xu | 4 Nov 06:33 2009
Picon

[PATCH 1/1] handle werid mbm card network name

---
 plugins/udev.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/plugins/udev.c b/plugins/udev.c
index c2e9c41..345613b 100644
--- a/plugins/udev.c
+++ b/plugins/udev.c
 <at>  <at>  -120,7 +120,8  <at>  <at>  static void add_mbm(struct ofono_modem *modem,
 		devnode = udev_device_get_devnode(udev_device);
 		ofono_modem_set_string(modem, GPS_DEVICE, devnode);
 	} else if (g_str_has_suffix(desc, "Minicard Network Adapter") ||
-			g_str_has_suffix(desc, "Broadband Network Adapter")) {
+			g_str_has_suffix(desc, "Broadband Network Adapter") ||
+				g_str_has_suffix(desc, "Minicard NetworkAdapter")) {
 		devnode = udev_device_get_property_value(udev_device,
 								"INTERFACE");
 		ofono_modem_set_string(modem, NETWORK_INTERFACE, devnode);
--

-- 
1.6.1.3

Marcel Holtmann | 4 Nov 06:54 2009

Re: [PATCH 1/1] handle werid mbm card network name

Hi Martin,

>  plugins/udev.c |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/plugins/udev.c b/plugins/udev.c
> index c2e9c41..345613b 100644
> --- a/plugins/udev.c
> +++ b/plugins/udev.c
>  <at>  <at>  -120,7 +120,8  <at>  <at>  static void add_mbm(struct ofono_modem *modem,
>  		devnode = udev_device_get_devnode(udev_device);
>  		ofono_modem_set_string(modem, GPS_DEVICE, devnode);
>  	} else if (g_str_has_suffix(desc, "Minicard Network Adapter") ||
> -			g_str_has_suffix(desc, "Broadband Network Adapter")) {
> +			g_str_has_suffix(desc, "Broadband Network Adapter") ||
> +				g_str_has_suffix(desc, "Minicard NetworkAdapter")) {
>  		devnode = udev_device_get_property_value(udev_device,
>  								"INTERFACE");
>  		ofono_modem_set_string(modem, NETWORK_INTERFACE, devnode);

are you serious? They forgot the space in one of their USB interface
descriptions.

Do me a favor and just add it between these two and don't bother with
the extra indentation. Two are enough.

Regards

Marcel

(Continue reading)

Martin Xu | 4 Nov 09:10 2009
Picon

index c2e9c41..6661074 100644


Xu, Martin | 4 Nov 09:12 2009
Picon

RE: [PATCH 1/1] handle werid mbm card network name

> -----Original Message-----
> From: ofono-bounces@...
[mailto:ofono-bounces@...] On Behalf
> Of Marcel Holtmann
> Sent: Wednesday, November 04, 2009 1:55 PM
> To: ofono@...
> Subject: Re: [PATCH 1/1] handle werid mbm card network name
> 
> Hi Martin,
> 
> >  plugins/udev.c |    3 ++-
> >  1 files changed, 2 insertions(+), 1 deletions(-)
> >
> > diff --git a/plugins/udev.c b/plugins/udev.c
> > index c2e9c41..345613b 100644
> > --- a/plugins/udev.c
> > +++ b/plugins/udev.c
> >  <at>  <at>  -120,7 +120,8  <at>  <at>  static void add_mbm(struct ofono_modem *modem,
> >  		devnode = udev_device_get_devnode(udev_device);
> >  		ofono_modem_set_string(modem, GPS_DEVICE, devnode);
> >  	} else if (g_str_has_suffix(desc, "Minicard Network Adapter") ||
> > -			g_str_has_suffix(desc, "Broadband Network Adapter")) {
> > +			g_str_has_suffix(desc, "Broadband Network Adapter") ||
> > +				g_str_has_suffix(desc, "Minicard NetworkAdapter")) {
> >  		devnode = udev_device_get_property_value(udev_device,
> >  								"INTERFACE");
> >  		ofono_modem_set_string(modem, NETWORK_INTERFACE, devnode);
> 
> are you serious? They forgot the space in one of their USB interface
> descriptions.
(Continue reading)

Martin Xu | 4 Nov 10:14 2009
Picon

[PATCH 1/1] Use AT+CFUN? to query powered state

---
 plugins/mbm.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/plugins/mbm.c b/plugins/mbm.c
index fd4569c..602709d 100644
--- a/plugins/mbm.c
+++ b/plugins/mbm.c
 <at>  <at>  -187,6 +187,9  <at>  <at>  static int mbm_enable(struct ofono_modem *modem)
 					NULL, NULL, NULL);
 	g_at_chat_send(data->chat, "AT*EMRDY?", none_prefix, NULL, NULL, NULL);

+	g_at_chat_send(data->chat, "AT+CFUN?", cfun_prefix,
+					cfun_query, modem, NULL);
+
 	return -EINPROGRESS;
 }

--

-- 
1.6.1.3


Gmane