Commit 5a3fc7a8 authored by Mark Pearson's avatar Mark Pearson Committed by Hans de Goede
Browse files

platform/x86: thinkpad_acpi: Simplify known_ev handling

parent 7545dc75
Loading
Loading
Loading
Loading
+2 −6
Original line number Diff line number Diff line
@@ -3845,6 +3845,7 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
		}

		send_acpi_ev = true;
		known_ev = false;

		switch (hkey >> 12) {
		case 1:
@@ -3868,8 +3869,6 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
				/* FIXME: kick libata if SATA link offline */
				known_ev = true;
				break;
			default:
				known_ev = false;
			}
			break;
		case 4:
@@ -3892,11 +3891,8 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
				tpacpi_send_radiosw_update();
				send_acpi_ev = 0;
				known_ev = true;
				break;
			}
			fallthrough;	/* to default */
		default:
			known_ev = false;
			break;
		}
		if (!known_ev) {
			pr_notice("unhandled HKEY event 0x%04x\n", hkey);