From nobody Fri Apr 19 22:48:59 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VLqZN1zckz5HtPB; Fri, 19 Apr 2024 22:49:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VLqZM6nrpz4Nsn; Fri, 19 Apr 2024 22:48:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713566940; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=E9BJymRe9w/ilBRw0hQ2V52w53baBqHxis5cjhWBZ7w=; b=ZNT/69A2Mp/9uu1IAvSItdWiMNrfSuo8uUFRXQ42vz0W9ngSFYf+z07sToi4hN4gbG3uq/ AeKB90d+o3BEfMty3pgHusW5kQygGRt+ZtD4EfeaKbT5Os+NrqbgYfoyIVFFYo/H6IgYdb ugw6URel5NOiRWvsn+E9YFepo/fC1QuusfpXinet/RMMuBI70Y5EhBuPiZf1PaR+FzWEo6 pEZ4YV+ST61vArdzAztIv6KBi8xmhC2mzz/2n98ZfBgKuJzHSaB8j43RLy7PFY93x0oXI/ RJU3gAZy6GcIAkTVHqEvUreYo/va8xUPjJpUXwyiAcTzXHmy6HfL9V3ROJFBVg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713566940; a=rsa-sha256; cv=none; b=D2LlUxaH0z2R0MMy8qXl1/lZqCDoDHEizP1AhECqyWF/gALC2N29ZtIMF57HG76vHRYCsb aJQA3ZysM7zC86IpCdiCsnZP0AvNjmu10De0HMkWVWZBxPhlYSiVdQt6NfePG+l0GhfBsd GKaIc3QrerOSx6kCOrVzfgzYpKhucJ0CYHskNFg2tNAibVAUph0/2uyc0R2EmAbtbjKwmN JZoKG0gxgU8ylk+cjVbhkrwb6atMdAcyXfQjs68iTwPu6GGlaWIfsuZqcwcdLn3MTNC5hB mUqUBXboyNMatfBWW5V4ip3pULd8Hgi/KvMOxf9TtExRf84rW67gD5nlrag1Ig== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713566940; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=E9BJymRe9w/ilBRw0hQ2V52w53baBqHxis5cjhWBZ7w=; b=IbZXjFbu49FGGMVbyDlazwHDnPco8aR1w91dSdjGMFJrn67cB6t7tEuZL0bO3jyAygCpzc hPNB5CTQdj/+hOVujvq7X/tyd3g5xlqT4sWGaaTMqVJaee51MpxU/wq3qAibPj6MSB3z44 0+AZyXmug3OAdpZ3PDHdWIIQ+qYuCWBVYaKabS4PTeg+bGkqnSCOG85BOp9AW6DCpPnab0 yxW5W4piey/4Eb5Z7cpVug1MKky61ilDmUFI+8/xHp8a4YbMpaqeARHc4rIXaTC7SvFXaz o/vCmxGIL5tgiDuD5xkLByC/ucon8hZZlbbXNQWS2Vcd9LsjNBt6Pr1gkvwkCA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4VLqZM6Q4Dz1BRT; Fri, 19 Apr 2024 22:48:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43JMmxpr010983; Fri, 19 Apr 2024 22:48:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43JMmxXZ010980; Fri, 19 Apr 2024 22:48:59 GMT (envelope-from git) Date: Fri, 19 Apr 2024 22:48:59 GMT Message-Id: <202404192248.43JMmxXZ010980@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 67677a654aa7 - main - acpi_iicbus: Shift slave address List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 67677a654aa7456f18077ccbaa9c40f39a36d21a Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=67677a654aa7456f18077ccbaa9c40f39a36d21a commit 67677a654aa7456f18077ccbaa9c40f39a36d21a Author: Ahmad Khalifa AuthorDate: 2024-04-19 22:43:19 +0000 Commit: Warner Losh CommitDate: 2024-04-19 22:44:57 +0000 acpi_iicbus: Shift slave address The address is expected to need shifting. see https://uefi.org/specs/ACPI/6.5/13_System_Mgmt_Bus_Interface_Specification.html#smbus-slave-addresses Reviewed by: imp, markj, Elliott Mitchell Pull Request: https://github.com/freebsd/freebsd-src/pull/1125 --- sys/dev/iicbus/acpi_iicbus.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/dev/iicbus/acpi_iicbus.c b/sys/dev/iicbus/acpi_iicbus.c index 2cff0cde9e48..4b61387b0ed6 100644 --- a/sys/dev/iicbus/acpi_iicbus.c +++ b/sys/dev/iicbus/acpi_iicbus.c @@ -254,6 +254,9 @@ acpi_iicbus_space_handler(UINT32 Function, ACPI_PHYSICAL_ADDRESS Address, sc = __containerof(info, struct acpi_iicbus_softc, space_handler_info); dev = sc->super_sc.dev; + /* the address is expected to need shifting */ + sb->SlaveAddress <<= 1; + switch (Function) { case AML_FIELD_ATTRIO(AML_FIELD_ATTRIB_SEND_RECEIVE, ACPI_READ): val = acpi_iicbus_recvb(dev, sb->SlaveAddress, gsb->data);