RE: [PATCH net-next-2.6 02/13] net-caif: add CAIF header files
From: Sjur Brændeland <hidden>
Date: 2010-01-22 08:59:05
Marcel Holtmann wrote:
quoted
... CAIFSO_CHANNEL is used for specifying the physical interface to use for the CAIF Channel. You can select the type of interface to use by setting link_selector: CAIF_PHYPREF_LOW_LAT will typically be used for AT (or other control traffic), and CAIF_PHYPREF_HIGH_BW for IP traffic. When the CAIF interfaces registers itself it will inform about their type, (low-latency or high-bandwidth). This approach assumes that you have only one modem, but multiple links to it (e.g. USB and UART). But you can also specify interface by name using link_name. In this case you specify the name of the interface to use. I think this would support your use case with multiple modems attached.sounds good, but why using a socket option and not allowing to just use bind(). Maybe it is just my personal preference, because I am used to do it like this for TCP and Bluetooth.
We actually considered this when designing the interface, but I don't feel bind() fits in this case. bind() would normally bind an address to the client socket. An interface did not seem like a client socket address to us, so we decided to use sockopt instead. Conceptually I don't think CAIF has a client address at all, it only connects to a server side address. BR/Sjur