Return-Path: From: Sumit Kumar BAJPAI To: Claudio Takahasi Cc: "linux-bluetooth@vger.kernel.org" Date: Wed, 12 Jan 2011 09:21:26 +0100 Subject: RE: [PATCH] HCI Commands for LE White List Message-ID: <4765B7BC10CB4C488A56C73E15D6FBA31DA381A6A5@EXDCVYMBSTM005.EQ1STM.local> References: <4765B7BC10CB4C488A56C73E15D6FBA31DA376A45B@EXDCVYMBSTM005.EQ1STM.local> In-Reply-To: Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Sender: linux-bluetooth-owner@vger.kernel.org List-ID: SGkgQ2xhdWRpbywNCg0KIA0KPiBDb3VsZCB5b3UgcGxlYXNlIHNwbGl0IHRoaXMgcGF0Y2ggaW50 byBtaW5vciBmdW5jdGlvbmFsIHBhdGNoZXM/DQpPay4gV291bGQgcmVzdWJtaXQgZm91ciBwYXRj aGVzIG5vdy1vbmUgZWFjaCBmb3IgQWRkIERldmljZSwgUmVtb3ZlIERldmljZSwgQ2xlYXIgV2hp dGUgTGlzdCBhbmQgUmVhZCBXaGl0ZSBMaXN0IHNpemUuDQoNCj4gDQo+IE9uIFRodSwgSmFuIDYs IDIwMTEgYXQgMTI6NTIgQU0sIFN1bWl0IEt1bWFyIEJBSlBBSQ0KPiA8c3VtaXRrdW1hci5iYWpw YWlAc3Rlcmljc3Nvbi5jb20+IHdyb3RlOg0KPiA+IEFkZGVkIEhDSSBjb21tYW5kcyBmb3IgTEUg V2hpdGUgTGlzdCBzdXBwb3J0Lg0KPiA+IFRoZXNlIExFIFdoaXRlIExpc3QgQ29tbWFuZHMgY2Fu IGJlIHRlc3RlZCBmcm9tDQo+ID4gaGNpdG9vbC4NCj4gPg0KPiA+DQo+ID4gLS0tDQo+ID4gwqBs aWIvaGNpLmMgwqAgwqAgwqAgfCDCoDEwNyArKysrKysrKysrKysrKysrKysrKysrKysrKysrKysr DQo+ID4gwqBsaWIvaGNpX2xpYi5oIMKgIHwgwqAgwqA0ICsNCj4gPiDCoHRvb2xzL2hjaX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