Ignore zero version date when comparing With [1], drivers will stop reporting the date: newer kernels will always report "0". Don't assume that the driver is older in that case. [1]: https://lore.kernel.org/all/20240510090951.3398882-1-jani.nikula@intel.com/
1 files changed, 2 insertions(+), 1 deletions(-) M drmtree/drmtree.go
M drmtree/drmtree.go => drmtree/drmtree.go +2 -1
@@ 36,7 36,8 @@ func (ver *DriverVersion) Less(other *DriverVersion) bool { } else if ver.Minor == other.Minor { if ver.Patch < other.Patch { return true } else if ver.Patch == other.Patch { } else if ver.Patch == other.Patch && ver.Date != "0" && other.Date != "0" { // "0" means unset return ver.Date < other.Date } }