Skip to content

serial: Cleanup & fix port discovery

Benjamin Herrenschmidt grub-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 3 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3serial: Replace usage of memcmp with strncmpgrub-core/term/serial.c+2 -20 replies
2/3serial: Avoid double lookup of serial portsgrub-core/term/arc/serial.c grub-core/term/ieee1275/serial.c grub-core/term/ns8250-spcr.c +3 more+33 -450 replies
3/3serial: Improve detection of duplicate serial portsgrub-core/term/arc/serial.c grub-core/term/ieee1275/serial.c grub-core/term/ns8250.c +2 more+51 -341 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/3] serial: Cleanup & fix port discovery

This series cleans up a few things in serial port discovery and fixes detection of duplicates in some cases:

- Existing usage of memcmp to compare strings is replaces with strncmp

- Don't lookup ports by name right after creating them, just return the pointer instead.

- Move the detection of duplicates *into* the various port creation functions. At this point, the various attributes such as port number and address have been properly parsed and there is no confusion between things like wether a 0x prefix is present or not for example, or wether hex digits are upper or lower case.