- Sep 09, 2019
-
-
Alexandre Bailon authored
There are a typo. We check that the kernel is higher than 4.9 but the error tells that a kernel 4.19 is required. Change it to 4.9. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
The curren way to test the kernel is not correct, and could fail even if the kernel is higher than expected. This fixes the kernel comparison. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Aug 06, 2019
-
-
Alexandre Bailon authored
A function from gbsim is used in main, even if gbsim has not been enabled. This fixes it. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
There is a build issue in tcpip controller. This fix it. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
This updates the README with more accurated instructions to build gbridge. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
GBDIR must be set in order to include the Greybus headers. Since Greybus has been merged to mainline kernel, we could just check if the current kernel >= 4.9, and use it's sources to build gbridge. If the kernel sources are not available, then GBDIR could be set manually. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
There were some error because gbridge was not handling this command correctly. This fixes the issue. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Aug 05, 2019
-
-
Alexandre Bailon authored
gbridge could simulate a real module. This is called GBSIM. This update README to talk about it. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
This uses mardown to format the README. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Mar 15, 2017
-
-
Alexandre Bailon authored
Add a .gitignore file to ignore some temporary files. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Add a gbsim controller and some greybus protocols. The current protocols supported are control and loopback. The control protocol is mandatory to enumerate the module. The loopback protocol is useful for testing. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Some controllers such as netlink must be registered before the others. Call register_controllers() before to register other controllers. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Add a variable to know if the thread is running or if must be cancelled on exit. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
In order to ease the debugging, add some debug logs. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
The function svc_interface_set_pwrm_request() send back the wrong status value. Update the status to GB_SVC_SETPWRM_PWR_OK. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, the function send the response to the wrong controller. Use get_connection() to get the right interface and the cport id. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, the only greybus protocol supported is SVC protocol. As the protocol is mandatory, there is no need to unregister it. But as we are going to support new protocols, add a way to unregister them. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Some operation handlers need to know the interface id . Add the interface id to the operation struct. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, all the greybus definitions are in gbridge.h. Add a greybus header to keep greybus definitions. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, gbridge can silently fail to start. Add more logs in the case of errors. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, netlink is mandatory and uses some specifics API. In order to make gbridge more scalable and generic, update netlink to register a controller. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Mar 11, 2017
-
-
Alexandre Bailon authored
In order to make controller more generic, use interface id and cport id to get a pointer to connection. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Mar 08, 2017
-
-
Alexandre Bailon authored
Curently, greybus use the hd cport id. It is fine except if we want to use the same code for AP or module. Use the interface and cport id which make greybus more generic. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Mar 07, 2017
-
-
Alexandre Bailon authored
Add the function hd_to_intf_cport_id() to get from the hd cport id the cport and interface id. This is required to deal with more than one interfaces on AP side. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, we only have one interface per connection. But we should have 2 interfaces to correctly represent a connection, as a connection is defined by a cport id and an interface id. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
In order to make the code more generic and runable on both AP and module side, we are going to use the cport and interface id instead ofhd cport id. But that means we need to be able to get the interface by using its id. Make get_interface() function public. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Mar 05, 2017
-
-
Alexandre Bailon authored
The gbridge.h header is using element defined in stdlib but it doesn't include it which every include to gbridge.h must be preceded by an include to stdlib.h. Include stdlib.h from gbridge.h. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
As I'm planning to add some other protocols, create a folder to store all protocols sources. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, all controllers' sources are in main sources folder. Move sources to a dedicated folder. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
The current status set in the response to GB_SVC_TYPE_INTF_SET_PWRM is not the one expected by Greybus. Set status to GB_SVC_SETPWRM_PWR_LOCAL. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Dec 26, 2016
-
-
Alexandre Bailon authored
We are creating and openning a connection but we are never destroying it. Register the connection_destroy callback. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Dec 22, 2016
-
-
Alexandre Bailon authored
gbridge has been written to work with the latest version of greybus available at the beginning of the project. But greybus has been updated and merge to kernel. Update gbridge to work with the latest version of greybus. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Add the macro REQUEST_NO_HANDLER() to define an operation handler without a callback. This will let us add new SVC operations without to have to implement them. Operation registered with REQUEST_NO_HANDLER() are not supposed to be used by the kernel in the current state, but if the kernel does, then gbridge will print an error. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
SVC operation are dispatched in SVC driver by switch case block. It works fine but it is hard to figure out which operation handler is complete, which one is just a stub method or which one is missing. In addition, it's not really scalable. By example, to print then of operation that failed, we will have to add and maintain another switch case block that print operation name (instead of operation type). Use new struct to register a callback and some other information about operation. Register all operation in an array and get the operation handler from it. In the case of failure, the operation dispatcher will be able get some additional information from the operation handler and give some details about the error. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Update log helpers to print errors in red and warnings in yellow. It should make more easier to see errors and warnings when they printed between greybus operation dump. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Dec 12, 2016
-
-
Alexandre Bailon authored
UART is not intended for production. The code is pretty bad and I don't plan to update it. Actually, it just make more easier to bring up support of Greybus to a new OS by using UART. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
interface_recv() is using the cport_id to get the connection struct. But unlike hd_cport_id which are unique for Greybus, some interface may use the same cport id. So to get the right connection struct, we must use both the interface and cport_id. Update cport_id_to_connection() to use both cport_id and intf. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Some controller may require some arguments such as device name. In that situation, the controller could not be registered from register_controllers() function. Make register_controller() public. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
Alexandre Bailon authored
Currently, there is two supported controller: TPC/IP and bluetooth. Add some options to enable or disable them at build time. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-
- Sep 28, 2016
-
-
Alexandre Bailon authored
Currently, without GB_SVC_TYPE_ROUTE_CREATE and GB_SVC_TYPE_ROUTE_DESTROY, Greybus won't correctly work. Add these two operations. Signed-off-by:
Alexandre Bailon <abailon@baylibre.com>
-