This commit adds a gen10 case to the switch statement and
drops some unneeded code for handling gen numbers which
doesn't work on gen10 and above.
V2: Drop "z = float(z)" and the "z *= 10" lines
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
${item.token_name}_${prop}(const struct gen_device_info *devinfo)
{
switch (devinfo->gen) {
+ case 10: return ${item.get_prop(prop, 10)};
case 9: return ${item.get_prop(prop, 9)};
case 8: return ${item.get_prop(prop, 8)};
case 7:
def __init__(self, z):
# Convert potential "major.minor" string
- z = float(z)
- if z < 10:
- z *= 10
- self.tenx = int(z)
+ self.tenx = int(float(z) * 10)
def __lt__(self, other):
return self.tenx < other.tenx