From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mx2.suse.de ([195.135.220.15]:36974 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726112AbeHEPyI (ORCPT ); Sun, 5 Aug 2018 11:54:08 -0400 Subject: Re: [RFC net-next 00/15] net: A socket API for LoRa To: Ben Whitten , Jian-Hong Pan Cc: "netdev@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , Jiri Pirko , Marcel Holtmann , "David S. Miller" , Matthias Brugger , Janus Piwek , =?UTF-8?Q?Michael_R=c3=b6der?= , Dollar Chen , Ken Yu , =?UTF-8?Q?Konstantin_B=c3=b6hm?= , Jan Jongboom , Jon Ortego , "contact@snootlab.com" , Brian Ray , "lora@globalsat.com.tw" , Alexander Graf , =?UTF-8?Q?Michal_Kube=c4=8dek?= , Hasnain Virk , Stefan Schmidt , "linux-wireless@vger.kernel.org" , "seth.forshee@canonical.com" , Daniele Comel , linux-wpan References: <20180701110804.32415-1-afaerber@suse.de> From: =?UTF-8?Q?Andreas_F=c3=a4rber?= Message-ID: (sfid-20180805_155015_050944_F2353F7E) Date: Sun, 5 Aug 2018 15:49:20 +0200 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Sender: linux-wireless-owner@vger.kernel.org List-ID: Hi Ben and Jian-Hong, [- SPI - devicetree] Am 18.07.2018 um 13:28 schrieb Ben Whitten: >> Meanwhile my attempt to play with netlink during SUSE >> Hackweek has been >> going slow and I could use some guidance or a volunteer to >> contribute: I >> have a bare skeleton of registration, commands, attributes >> and multicast >> groups, but no plan yet how to connect that to the actual >> drivers to >> query or apply the settings... > > Happy to help, I will be starting from zero on netlink but I can contribute my existing work incorporating Marks comments for sx1301 etal. I've figured out a way to retrieve a frequency value via netlink: By passing the lora0 ifindex in as attribute, nllora can look up the net_device by index, and then via struct lora_dev_priv call into hooks that the device drivers can optionally implement. :) https://git.kernel.org/pub/scm/linux/kernel/git/afaerber/linux-lora.git/tree/net/lora/netlink.c?h=lora-next Tested with HIMO-01M module. The command might need an additional channel attribute for SX130x. The corresponding nltest program (using libnl-genl) is here: https://github.com/afaerber/lora-modules/blob/master/nltest.c Cheers, Andreas -- SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?UTF-8?Q?Andreas_F=c3=a4rber?= Subject: Re: [RFC net-next 00/15] net: A socket API for LoRa Date: Sun, 5 Aug 2018 15:49:20 +0200 Message-ID: References: <20180701110804.32415-1-afaerber@suse.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Cc: "netdev@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , Jiri Pirko , Marcel Holtmann , "David S. Miller" , Matthias Brugger , Janus Piwek , =?UTF-8?Q?Michael_R=c3=b6der?= , Dollar Chen , Ken Yu , =?UTF-8?Q?Konstantin_B=c3=b6hm?= , Jan Jongboom , Jon Ortego , "contact@snootlab.com" , Brian Ray , "lora@globalsat.com.tw" , Jian-Hong Pan Return-path: In-Reply-To: Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-Id: netdev.vger.kernel.org Hi Ben and Jian-Hong, [- SPI - devicetree] Am 18.07.2018 um 13:28 schrieb Ben Whitten: >> Meanwhile my attempt to play with netlink during SUSE >> Hackweek has been >> going slow and I could use some guidance or a volunteer to >> contribute: I >> have a bare skeleton of registration, commands, attributes >> and multicast >> groups, but no plan yet how to connect that to the actual >> drivers to >> query or apply the settings... > > Happy to help, I will be starting from zero on netlink but I can contribute my existing work incorporating Marks comments for sx1301 etal. I've figured out a way to retrieve a frequency value via netlink: By passing the lora0 ifindex in as attribute, nllora can look up the net_device by index, and then via struct lora_dev_priv call into hooks that the device drivers can optionally implement. :) https://git.kernel.org/pub/scm/linux/kernel/git/afaerber/linux-lora.git/tree/net/lora/netlink.c?h=lora-next Tested with HIMO-01M module. The command might need an additional channel attribute for SX130x. The corresponding nltest program (using libnl-genl) is here: https://github.com/afaerber/lora-modules/blob/master/nltest.c Cheers, Andreas -- SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) From mboxrd@z Thu Jan 1 00:00:00 1970 From: afaerber@suse.de (=?UTF-8?Q?Andreas_F=c3=a4rber?=) Date: Sun, 5 Aug 2018 15:49:20 +0200 Subject: [RFC net-next 00/15] net: A socket API for LoRa In-Reply-To: References: <20180701110804.32415-1-afaerber@suse.de> Message-ID: To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi Ben and Jian-Hong, [- SPI - devicetree] Am 18.07.2018 um 13:28 schrieb Ben Whitten: >> Meanwhile my attempt to play with netlink during SUSE >> Hackweek has been >> going slow and I could use some guidance or a volunteer to >> contribute: I >> have a bare skeleton of registration, commands, attributes >> and multicast >> groups, but no plan yet how to connect that to the actual >> drivers to >> query or apply the settings... > > Happy to help, I will be starting from zero on netlink but I can contribute my existing work incorporating Marks comments for sx1301 etal. I've figured out a way to retrieve a frequency value via netlink: By passing the lora0 ifindex in as attribute, nllora can look up the net_device by index, and then via struct lora_dev_priv call into hooks that the device drivers can optionally implement. :) https://git.kernel.org/pub/scm/linux/kernel/git/afaerber/linux-lora.git/tree/net/lora/netlink.c?h=lora-next Tested with HIMO-01M module. The command might need an additional channel attribute for SX130x. The corresponding nltest program (using libnl-genl) is here: https://github.com/afaerber/lora-modules/blob/master/nltest.c Cheers, Andreas -- SUSE Linux GmbH, Maxfeldstr. 5, 90409 N?rnberg, Germany GF: Felix Imend?rffer, Jane Smithard, Graham Norton HRB 21284 (AG N?rnberg)