Return-Path: MIME-Version: 1.0 In-Reply-To: References: <554E804F.9090407@lwfinger.net> <54F70642BAB21D4498E1AA3EFE3D519A461012DA@rsex2.realsil.com.cn> <54F70642BAB21D4498E1AA3EFE3D519A46101882@rsex2.realsil.com.cn> <54F70642BAB21D4498E1AA3EFE3D519A4610F810@rsex2.realsil.com.cn> Date: Thu, 28 May 2015 08:48:32 -0600 Message-ID: Subject: Re: Realtek USB bluetooth: no scan results when wifi is connected From: Daniel Drake To: Marcel Holtmann Cc: =?UTF-8?B?6ZmI6Imz6JCN?= , Larry Finger , Carlo Caione , Linux Bluetooth mailing list , "shaofu@realtek.com > shaofu" , =?UTF-8?B?5byg5b+X56Wl?= , =?UTF-8?B?6ZmG5pyx5Lyf?= , Chih-Hsiang Wang , =?UTF-8?B?5q+b5Li66ZSL?= , "pkshih@realtek.com" Content-Type: text/plain; charset=UTF-8 List-ID: On Thu, May 28, 2015 at 8:23 AM, Marcel Holtmann wrote: > Hi Champion, > >> We want to share some information between wifi driver and bt driver, what rules do you recommend for the following situation ? >> 1. at system startup, bluetooth driver want to read some information (eg antenna settings) that generated by wifi , shall we use files or /proc/ information? >> 2. when user is using Bluetooth, bt driver may notify wifi driver to perform better, shall we use socket to communication? > > this is the Bluetooth subsystem communicating with the WiFi subsystem (cfg80211) and vice versa, then this is happening inside the kernel. I do not see any need to even try to go via userspace at all. So neither /proc and no sockets for this. I agree. But can we give more specific advice on how to do this inside the kernel? i.e. should they create a new driver under drivers/misc which exposes a shared API via EXPORT_SYMBOL? The other option for Realtek to consider is to do this in hardware/firmware. I already saw that the btcoexist driver knows exactly when the wifi and BT start and finish scanning, so there is clearly already an information-passing mechanism between the two interfaces. I wonder if an updated firmware could extend that to include the new information that you wish to additionally transfer. Daniel