Am 02.09.2018 um 11:28 schrieb Stefan Seyfried:
Am 02.09.2018 um 07:23 schrieb Simon Lees:
On 31/08/2018 16:38, Michal Kubecek wrote:
On Friday, 31 August 2018 8:20 Per Jessen wrote:
Andrei Borzenkov wrote:
30.08.2018 14:57, Per Jessen ?????:
32 does seem a pretty odd default.
Right - I guess it's a kernel default that was changed at some point. For amusement, going even further back in time - in 2.6.25 :
CONFIG_SERIAL_8250_NR_UARTS=4 CONFIG_SERIAL_8250_RUNTIME_UARTS=4
OK, let's go for some amusement. We have such tool, it's called "git" and it can tell you rather quickly where that "some point" was. And in this particular case, it could even point you to bsc#652954 and this bug then to
http://www.spinics.net/lists/linux-serial/msg03020.html
I don't say I agree with the reasoning, personally I think that four would be reasonable default for openSUSE (and you don't even have to put the module parameter on kernel command line, that's what /etc/modprobe.d exists for), but there is really no need to pretend there is some dark mystery about the change(s).
Personally I think 4 is too low, especially for those who have worked in electrical engineering contexts, at my last job I commonly had 8-10 ports sometimes more, this was partly because I had a 8 port moxa box
boot parameter 8250.nr_uarts=32 will give you the old behaviour back.
Granted I'm an extreme case but given makers / hackers are one of our target audiences I can easily see some of them frequently using more then 4.
I can easily see them adding a simple boot parameter :-)
Really? I've just been faced with this topic on arm64. I came to the conclusion, based on what is there for x86_64 and others, that it's much easier for me and other users that mind it to _lower_ the number of ttyS devices via /etc/default/grub config than to run into situations where the port you expect just doesn't show up and you don't know why. http://bugzilla.opensuse.org/show_bug.cgi?id=1073193 So really there's two topics being mixed: 1) The maximum number of possible ttyS devices. 2) The number of ttyS devices actually shown in the file system. The first is a decision that every serial driver is faced with. For 8250 the Kconfig documentation is not entirely clear and you only fully understand by reading what 8250_core.c does with the symbols: NR_UARTS is merely an upper bound and you need to set RUNTIME_UARTS high enough. Replacing the static port arrays used in virtually all serial drivers with a linked list would make the lookup go from O(1) to O(n), but with numbers up to 32 that might not matter that much? The present ttyS devices seem an ugliness specific to the 8250 driver, and jslaby's argumentation for having them around doesn't apply to other architectures or at least I don't see why this one subsystem should allow to override any ACPI/DT-supplied configuration. Getting 8250 more in line with other serial drivers so that ttyS devices only show up after initialized (think ttyUSB) would be the most elegant solution, and I assume the number of users complaining would be as low as those complaining about NR_CPUS being higher than their respective system has. Until then, keeping a high default seems safest for those that may want to hot-plug ports and for whom rebooting to bump 8250.nr_uarts would be inconvenient. Keep in mind not every openSUSE user runs a desktop. It'll also save kernel engineers from "invalid" Bugzilla tickets. In the end, whatever we do about the 32 ttyS*, let's not forget there's still the 64 tty* next to them. And if some program looked specifically at ttyS rather than tty, then it would miss ttyUSB, ttyACM, ttyAMA and many other alternative device file names. Regards, Andreas -- SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org