[LEDE-DEV] [PATCH 3/3] usbmode: remove devices with unsupported modes

Bjørn Mork bjorn at mork.no
Fri Dec 22 01:48:36 PST 2017


Julian Labus <julian at labus-online.de> writes:

> diff --git a/package/utils/usbmode/Makefile b/package/utils/usbmode/Makefile
> index 7f0195fdce..1b1ef147b6 100644
> --- a/package/utils/usbmode/Makefile
> +++ b/package/utils/usbmode/Makefile
> @@ -40,8 +40,13 @@ endef
>  define Build/Prepare
>  	$(Build/Prepare/Default)
>  	tar xvfj $(DL_DIR)/$(PKG_DATA_FILENAME) -C $(PKG_BUILD_DIR)
> -	rm -f \
> -		$(PKG_BUILD_DIR)/$(PKG_DATA_PATH)/usb_modeswitch.d/05c6:1000:sVe=GT
> +	#remove devices with unsupported modes
> +	for filevar in $(PKG_BUILD_DIR)/$(PKG_DATA_PATH)/usb_modeswitch.d/* ; \
> +	do \
> +		if grep -q -E '(Quanta|Option|Blackberry|Pantech)Mode' "$$$$filevar" ; then \
> +			rm "$$$$filevar" ; \
> +		fi \
> +	done
>  	cp ./data/* $(PKG_BUILD_DIR)/$(PKG_DATA_PATH)/usb_modeswitch.d/
>  	#in order to keep the Lede GIT repo free of filenames with colons,
>  	#we name the files xxxx-yyyy


Sorry for the extremely late comment on this.  I missed the discussion
when it happened, but was made aware of it now because users with Option
modems complain that the modems have stopped working with LEDE.

This patch is papering over a regression introduced by updating the data
package.  I strongly object to that sort of bug "fixing".  Option modems
used to work with the old data package, as it included the explicit
message for each Option device entry.  Adding new modems does not
justify dropping support for older modems.

Please fix this properly instead if you want to update to the config
data.


Bjørn



More information about the Lede-dev mailing list