Date: Sat, 14 Feb 2009 09:52:58 +0000 (GMT) From: Iain Hibbert <plunky@rya-online.net> To: Maksim Yevmenkin <maksim.yevmenkin@gmail.com> Cc: "freebsd-bluetooth@freebsd.org" <freebsd-bluetooth@freebsd.org> Subject: Re: libhci Message-ID: <1234605178.990729.799.nullmailer@galant.ukfsn.org> In-Reply-To: <bb4a86c70902131717o2ccc1fd2nd73f84b1a7765152@mail.gmail.com> References: <1233365217.00068654.1233354838@10.7.7.3> <4988DCCC.80201@mavhome.dp.ua> <bb4a86c70902031622hdc5231g1c9ce33f17842a1e@mail.gmail.com> <4988EBAC.3080202@mavhome.dp.ua> <bb4a86c70902031731q83bf261s49e5812a3c208f81@mail.gmail.com> <1233758519.360141.162.nullmailer@galant.ukfsn.org> <bb4a86c70902041000t26ad9b66q94a32ff37cfb7f4b@mail.gmail.com> <1233845167.798942.24919.nullmailer@galant.ukfsn.org> <bb4a86c70902051001j53f52e3dhb2e80e393b936f16@mail.gmail.com> <1233919880.530235.10843.nullmailer@galant.ukfsn.org> <bb4a86c70902131717o2ccc1fd2nd73f84b1a7765152@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 13 Feb 2009, Maksim Yevmenkin wrote: > i kinda started to work on hci/bluetooth shims. please take a look at > the attached patch. this is basically to implement bt_devname() and > bt_devaddr() similar to netbsd and i also added bt_hci_devinfo() and > bt_hci_devenum() inspired by linux-bluez. some quick comments as I'm on battery and ENOTIME - I think it should lose the "_hci" part of the name :) - count = bt_devenum(cb, arg) no limits in API (no objection to underlying implementation limit :) the callback can signal, if it has seen enough. (could allow callback=NULL to just count the devices) - len = bt_devinfo(name, buffer, sizeof(buffer)) the calling program gives buffer and size, allowing the devinfo to be extended later without breaking ABI. len == 0 means not found also, reserved slots in the structure become unnecessary, let the compiler handle padding. (size and name could be passed in devinfo?) (is variable size struct perhaps too ugly to handle? what about 'version' field?) iain
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1234605178.990729.799.nullmailer>