Skip to contentSkip to conversation

package/avrdude: add linux gpio kconfig option

PATCH New Matt Weber 4 participants 8 messages May 18, 2017 – May 19, 2017

lore
Share & tools
lore

Matt Weber

author
#0 lore raw

PATCH v2 1/2 package/avrdude: add linux gpio kconfig option

From: Sam Voss <[email protected]>

Add the option to enable linux sysfs gpio framework configure option in menuconfig.

---

Change Log

v1 -> v2
- upstream accepted linux gpio fix, removed patch

---
 package/avrdude/Config.in  | 10 ++++++++++
 package/avrdude/avrdude.mk |  6 ++++++
 2 files changed, 16 insertions(+)
package/avrdude/Config.in +10 -0
index 3757f17..ac982e1 100644
@@ -15,6 +15,16 @@ config BR2_PACKAGE_AVRDUDE
 
 	  https://github.com/kcuzner/avrdude
 
+if BR2_PACKAGE_AVRDUDE
+
+config BR2_PACKAGE_AVRDUDE_LINUXGPIO
+	bool "linux gpio"
+	depends on BR2_PACKAGE_AVRDUDE
+	help
+	  Enables the tool to use the Linux Sysfs based GPIO framework for GPIO
+	  access by configuring AVRDude with '--enable-linuxgpio'.
+endif
+
 comment "avrdude needs a uClibc or glibc toolchain w/ threads, wchar, dynamic library"
 	depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR || BR2_STATIC_LIBS \
 		|| !(BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_GLIBC)
package/avrdude/avrdude.mk +6 -0
index f914ed7..19ffdfa 100644
@@ -23,6 +23,12 @@ else ifeq ($(BR2_PACKAGE_LIBFTDI),y)
 AVRDUDE_DEPENDENCIES += libftdi
 endif
 
+ifeq ($(BR2_PACKAGE_AVRDUDE_LINUXGPIO),y)
+AVRDUDE_CONF_OPTS = --enable-linuxgpio
+else
+AVRDUDE_CONF_OPTS = --disable-linuxgpio
+endif
+
 # if /etc/avrdude.conf exists, the installation process creates a
 # backup file, which we do not want in the context of Buildroot.
 define AVRDUDE_REMOVE_BACKUP_FILE
Signature · 1 line
1.9.1
author
#1 lore raw

PATCH v2 2/2 package/avrdude: bump to f8893ccf0aceeff67c45f95ae4e86bc7fbe342aa

---
Change log
v1 -> v2
- Bump for upstream accepting fix

---
 package/avrdude/avrdude.hash | 2 +-
 package/avrdude/avrdude.mk   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
package/avrdude/avrdude.hash +1 -1
index b2c6125..b203d4d 100644
@@ -1,2 +1,2 @@
 # Locally computed
-sha256 b32128f4812d5e852cfba2e863d950ec30e0f72f09bc14fb41c02528bbc5dd18 avrdude-ad04c429a90f4c34f000ea4ae11db2705915a31f.tar.gz
+sha256 cfa97af7badc713c62306ab85d0e7a288b064bf72e698494f73cb16c5b2c659e avrdude-f8893ccf0aceeff67c45f95ae4e86bc7fbe342aa.tar.gz
package/avrdude/avrdude.mk +1 -1
index 19ffdfa..5d5debb 100644
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-AVRDUDE_VERSION = ad04c429a90f4c34f000ea4ae11db2705915a31f
+AVRDUDE_VERSION = f8893ccf0aceeff67c45f95ae4e86bc7fbe342aa
 AVRDUDE_SITE = $(call github,kcuzner,avrdude,$(AVRDUDE_VERSION))
 AVRDUDE_LICENSE = GPL-2.0+
 AVRDUDE_LICENSE_FILES = avrdude/COPYING
Signature · 1 line
1.9.1
#2 lore raw

PATCH v2 1/2 package/avrdude: add linux gpio kconfig option

In reply to Matt Weber
Quoted 9 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Matt" == Matt Weber <[email protected]> writes:

From: Sam Voss <[email protected]> Add the option to enable linux sysfs gpio framework configure option in menuconfig.

Quoted 6 lines

---

Change Log

v1 -> v2
- upstream accepted linux gpio fix, removed patch

Didn't you just agree with Baruch that we could just enable it unconditially and not have a Config.in option for it?

Signature · 1 line
Bye, Peter Korsgaard
#3 lore raw

PATCH v2 1/2 package/avrdude: add linux gpio kconfig option

Peter / Baruch,

Quoted 12 lines · Peter Korsgaard
Quoted 11 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

"Matt" == Matt Weber <[email protected]> writes:

From: Sam Voss <[email protected]> Add the option to enable linux sysfs gpio framework configure option in menuconfig.

---

Quoted 8 lines
Quoted 4 lines

Change Log

v1 -> v2
- upstream accepted linux gpio fix, removed patch

Didn't you just agree with Baruch that we could just enable it unconditially and not have a Config.in option for it?

Not sure we reached a conclusion. I guess the question would be, right now in buildroot it doesn't enable this option. So if we by default go linux-gpio it disables the legacy options which were the previous default (kernel's older then sysfs gpio support). I'm good either way, but the fundamental package behavior changes.

Matt

#4 lore raw

PATCH v2 1/2 package/avrdude: add linux gpio kconfig option

Hello,

Quoted 5 lines · Matthew Weber

Not sure we reached a conclusion. I guess the question would be, right now in buildroot it doesn't enable this option. So if we by default go linux-gpio it disables the legacy options which were the previous default (kernel's older then sysfs gpio support). I'm good either way, but the fundamental package behavior changes.

Package behavior also changes every time we bump a package. So Baruch's question was whether the size impact was significant or not. If it's not, then no need to make an option for it.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
#5 lore raw

PATCH v2 1/2 package/avrdude: add linux gpio kconfig option

In reply to Matthew Weber
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Matthew" == Matthew Weber <[email protected]> writes:

Hi,

Quoted 8 lines
Quoted 3 lines

Didn't you just agree with Baruch that we could just enable it unconditially and not have a Config.in option for it?

Not sure we reached a conclusion. I guess the question would be, right now in buildroot it doesn't enable this option. So if we by default go linux-gpio it disables the legacy options which were the previous default (kernel's older then sysfs gpio support)

Do you mean that enabling this driver disables anything else? I don't see that. The kernel's gpio sysfs interface is close to 10 years old by now, so I doubt that is an issue.

From the looks of it, the linuxgpio driver seems to be very small compared to the total size of avrdude, so unconditionally enabling it sounds sensible to me.

I notice that we are using a fork of avrdude which hasn't really been updated significantly since 2013 instead of the official one which had a release in 2016. Any reason we shouldn't be using the official one instead?

Signature · 1 line
Bye, Peter Korsgaard
#6 lore raw

PATCH v2 1/2 package/avrdude: add linux gpio kconfig option

Peter

Quoted 13 lines · Peter Korsgaard
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Matthew" == Matthew Weber <[email protected]> writes:

Hi,

Quoted 8 lines
Quoted 3 lines

Didn't you just agree with Baruch that we could just enable it unconditially and not have a Config.in option for it?

Not sure we reached a conclusion. I guess the question would be, right now in buildroot it doesn't enable this option. So if we by default go linux-gpio it disables the legacy options which were the previous default (kernel's older then sysfs gpio support)

Quoted 7 lines

Do you mean that enabling this driver disables anything else? I don't see that. The kernel's gpio sysfs interface is close to 10 years old by now, so I doubt that is an issue.

From the looks of it, the linuxgpio driver seems to be very small compared to the total size of avrdude, so unconditionally enabling it sounds sensible to me.

Ok, I'm good with unconditionally enabling.

Quoted 5 lines

I notice that we are using a fork of avrdude which hasn't really been updated significantly since 2013 instead of the official one which had a release in 2016. Any reason we shouldn't be using the official one instead?

Very good question, we are unsure. I've added a few people that have modified that package to this email to ask.

Wojciech / Samuel / Gregory, any reason to stay on this fork of avrdude?

Matt

#7 lore raw

PATCH v2 1/2 package/avrdude: add linux gpio kconfig option

Quoted 9 lines
Quoted 4 lines

I notice that we are using a fork of avrdude which hasn't really been updated significantly since 2013 instead of the official one which had a release in 2016. Any reason we shouldn't be using the official one instead?

Very good question, we are unsure. I've added a few people that have modified that package to this email to ask.

Wojciech / Samuel / Gregory, any reason to stay on this fork of avrdude?

The biggest reason is due to the fact that the spi functionality has not been merged back into mainline, and requests to do it have fallen onto deaf ears. I sent an email recently to the mainline avrdude asking about getting this functionality merged in and have yet to hear anything from them.

Signature · 1 line
Sam Voss