Return-Path: From: Ilya Faenson To: Frederic Danis , "linux-bluetooth@vger.kernel.org" CC: Arend Van Spriel Subject: RE: [PATCH 1/3] Bluetooth: hci_uart: Add PM for BCM2E39 Date: Thu, 16 Jul 2015 18:54:39 +0000 Message-ID: References: <1435929751-26831-1-git-send-email-frederic.danis@linux.intel.com> <55A7D771.9020705@linux.intel.com> In-Reply-To: <55A7D771.9020705@linux.intel.com> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Sender: linux-bluetooth-owner@vger.kernel.org List-ID: SGkgRnJlZCwNCg0KLS0tLS1PcmlnaW5hbCBNZXNzYWdlLS0tLS0NCkZyb206IGxpbnV4LWJsdWV0 b290aC1vd25lckB2Z2VyLmtlcm5lbC5vcmcgW21haWx0bzpsaW51eC1ibHVldG9vdGgtb3duZXJA dmdlci5rZXJuZWwub3JnXSBPbiBCZWhhbGYgT2YgRnJlZGVyaWMgRGFuaXMNClNlbnQ6IFRodXJz ZGF5LCBKdWx5IDE2LCAyMDE1IDEyOjEwIFBNDQpUbzogbGludXgtYmx1ZXRvb3RoQHZnZXIua2Vy bmVsLm9yZw0KU3ViamVjdDogUmU6IFtQQVRDSCAxLzNdIEJsdWV0b290aDogaGNpX3VhcnQ6IEFk ZCBQTSBmb3IgQkNNMkUzOQ0KDQpQaW5nID8NCg0KT24gMDMvMDcvMjAxNSAxNToyMiwgRnJlZGVy aWMgRGFuaXMgd3JvdGU6DQo+IFJldHJpZXZlICJzaHV0ZG93biIgYW5kICJkZXZpY2Vfd2FrZXVw IiBHUElPcyBmcm9tIEFDUEkuDQo+IFNldCBkZXZpY2Ugb2ZmIGR1cmluZyBwbGF0Zm9ybSBkZXZp Y2UgZW51bWVyYXRpb24uDQo+IFNldCBkZXZpY2Ugb24gb25seSB3aGVuIGl0IGlzIGF0dGFjaGVk Lg0KDQpJRjogU29ycnkgZm9yIHRoZSBkZWxheSBpbiByZXNwb25kaW5nLiBJIGFtIG5vdCBhY3Rp dmVseSB3b3JraW5nIG9uIH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