linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Gustavo F. Padovan" <padovan@profusion.mobi>
To: Waldemar.Rymarkiewicz@tieto.com
Cc: marcel@holtmann.org, linux-bluetooth@vger.kernel.org,
	suraj@atheros.com, johan.hedberg@gmail.com,
	joakim.xj.ceder@stericsson.com
Subject: Re: [PATCH 1/4] Sim Access Profile API
Date: Wed, 10 Nov 2010 14:07:57 -0200	[thread overview]
Message-ID: <20101110160757.GC3275@vigoh> (raw)
In-Reply-To: <99B09243E1A5DA4898CDD8B7001114480BD700C239@EXMB04.eu.tieto.com>

Hi Waldemar,

* Waldemar.Rymarkiewicz@tieto.com <Waldemar.Rymarkiewicz@tieto.com> [2010-11-10 13:12:53 +0200]:

> Hi Marcel, 
> 
> >> +		void Disable()
> >> +
> >> +			Shudown SAP server and remove the SDP record.
> >> +
> >> +			Possible errors: org.bluez.Error.Failed
> >
> >I don't like this. If you have properties then just changing 
> >the property should be enough. So a SetProperty is more appropriate.
> 
> I see another option to get rid of 'Enabled' property and leave the methods. What would you say on that?

It's not a good a idea. We have been moving everything we can to a set
property operation instead of a method call. Do that as method is add
unnecessary code to BlueZ once we already have set property there.

> 
> >> +
> >> +		void Disconnect(boolean type)
> >> +
> >> +			Disconnect SAP client from the server. 
> >The 'type'
> >> +			parameter indicates disconnection type.
> >> +
> >> +			True  - gracefull disconnection
> >> +			False - immediate disconnection
> >> +
> >> +			Possible errors: org.bluez.Error.Failed
> >
> >I don't like this style of method names at all. Using method 
> >names like GracefulDisconnect and ImmediateDisconnect would be better.
> 
> That's fine.
> 
> >However I am not sure we should differentiate here at all. We 
> >should always to the graceful disconnect. What will the 
> >immediate disconnect bring us?
> 
> That's actually intended for testing only. One of PTS test cases expects the tester to trigger immediate disconnect.
> In practce, it is only used when connection to sim card is lost, but this is obviously done internally.


So this shouldn't be in the API, no one is going to use it. You can
create something internally for the immediate disconnection that you go
and set manually inside the code. Make sure to comment in the code why
you are adding this there. That can also be a option in some of the
bluetooth config files. Let's see what others think here.

-- 
Gustavo F. Padovan
http://profusion.mobi

  reply	other threads:[~2010-11-10 16:07 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-03 13:34 [PATCH 0/4] Sim Access Profile Waldemar Rymarkiewicz
2010-11-03 13:34 ` [PATCH 1/4] Sim Access Profile API Waldemar Rymarkiewicz
2010-11-10  5:33   ` Marcel Holtmann
2010-11-10 11:12     ` Waldemar.Rymarkiewicz
2010-11-10 16:07       ` Gustavo F. Padovan [this message]
2010-11-10 21:46         ` Luiz Augusto von Dentz
2010-11-15 17:29           ` Waldemar.Rymarkiewicz
2010-11-03 13:34 ` [PATCH 2/4] Sim Access Profile Manager Waldemar Rymarkiewicz
2010-11-05  9:30   ` Johan Hedberg
2010-11-05 13:31     ` Waldemar.Rymarkiewicz
2010-11-03 13:34 ` [PATCH 3/4] Sim Access Profile Server Waldemar Rymarkiewicz
2010-11-05 10:05   ` Johan Hedberg
2010-11-05 15:12     ` Waldemar.Rymarkiewicz
2010-11-03 13:34 ` [PATCH 4/4] Sim Access Profile dummy driver Waldemar Rymarkiewicz
2010-11-05 10:16   ` Johan Hedberg
2010-11-05 15:14     ` Waldemar.Rymarkiewicz
  -- strict thread matches above, loose matches on Subject: below --
2010-12-02 14:14 [PATCH 1/4] Sim Access Profile API Waldemar Rymarkiewicz
2010-12-02 15:19 ` Gustavo F. Padovan
2010-12-02 15:23   ` Waldemar.Rymarkiewicz
2010-12-14 15:16     ` Waldemar.Rymarkiewicz
2010-10-20 12:11 Waldemar Rymarkiewicz

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=20101110160757.GC3275@vigoh \
    --to=padovan@profusion.mobi \
    --cc=Waldemar.Rymarkiewicz@tieto.com \
    --cc=joakim.xj.ceder@stericsson.com \
    --cc=johan.hedberg@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=marcel@holtmann.org \
    --cc=suraj@atheros.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;
as well as URLs for NNTP newsgroup(s).