Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp108009ybb; Thu, 19 Mar 2020 12:31:08 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuIaiEuR83nVS6pDlVbbqBSGGAhaH77+XmrrNK3mlGXjSQikGYKYMTgciz68UiEcMCnMtfK X-Received: by 2002:aca:4142:: with SMTP id o63mr3504638oia.118.1584646268214; Thu, 19 Mar 2020 12:31:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584646268; cv=none; d=google.com; s=arc-20160816; b=l5pZuNjhZJH6GpdmwprVYrw7Rk/3wlOboecRStXwM6A5c6wchvYl9DCBeRUl2iccnQ gRl1GMWTHEYDrq9HvbCXwBoX7zf50opneu9JVgaxXuDy++O8mLBqhKQetCVlD+s8v322 jry33YF5Iu+CM2qYdZP8GKYhvfNrE4xarTDD++lofOpROdapHWXU33Hc7pN0MpnwL6r4 LvrjEFteQx9bCoh2COQneclWech+IdYm6e1Y1VlNXXqY7jgwPPs1okhCSReykuYc6Ozq DcsMv9yqudCrtkgB6ULJ9xiWM8jBaKNw9vvuLi8iFSZorASaCVLU1dLG4zaLBp8Zhpqj KTjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=2CiSuKaNodoKyjnGemNKoIzUpiAYvV52BwWj4otjji0=; b=tX1m1KoCcEAZMpGnghdbfcEU+ar5ES/SHuaUxg9vaG+4AofpW7aGvuOlBixTDgrUy6 F4+8lfsYUhuxbzr447sbFhJ8tq/abg3hSYsRgsecBiOPTjhfiUHJVKbq35lROsVWqhMC C8anczZaUtPXp6ZJ9hqMLLEPa2dQjS42vBAp7B0qKdu1RBkIbgQuPYM+I0Y3zN+hsnrw PNF4bR22CWrzZxVGIDdXYZvWC0owuKeNQ9aifuzsFJXS7wWI3/f06FuIzXXhKbb1ZK2n k3kAHQICmidavBIVNVKZRZny9jq/npLvsvt4UnnsKsWn7Xps9Oht+OXe4wm/UVQz5/cs JbmQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l25si1373803oii.205.2020.03.19.12.30.55; Thu, 19 Mar 2020 12:31:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728059AbgCST3g (ORCPT + 99 others); Thu, 19 Mar 2020 15:29:36 -0400 Received: from mail-qk1-f195.google.com ([209.85.222.195]:41086 "EHLO mail-qk1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727721AbgCST3G (ORCPT ); Thu, 19 Mar 2020 15:29:06 -0400 Received: by mail-qk1-f195.google.com with SMTP id s11so4398233qks.8; Thu, 19 Mar 2020 12:29:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=2CiSuKaNodoKyjnGemNKoIzUpiAYvV52BwWj4otjji0=; b=lRHlKMhbrRb01jT25sqpnqPRK8ello5cKqPBZVxcHNkGQbpdOqsqwFK6uMnLnMJVzI dlEfxjd3lyH05V/AruZ2gTibT+TKqRiSXZfI6x5AIByBcHLXQUj6sfyYd9/Zh5/9xrSu uLOOlZ9P4fpLYaayPWNM9fQPfavWKPKQQ+ki2ccsr3ZW1VWDFSsJcmtUC8Soa45KSvgT uQlEejJAwZXLHKTSdHs/Zjqf1/NvXsEjgwt+40s68I0GZfukNZZePlVQgtrGi4mDZsB4 WyRyePiy57hOcrD5xYlDQDq6C9CksYmIJBk5f1fDwL6iVU5gS4Mq1pekWpsrUZfPsQAz DpiQ== X-Gm-Message-State: ANhLgQ3QAw2FDScLyoZ+mv8R3m1Yy4xDttuuXNPzOu2fEl2VaX1eJ6OH bNEo1HwXFtb7fnhbMP8o2iA= X-Received: by 2002:a37:981:: with SMTP id 123mr4653512qkj.154.1584646145999; Thu, 19 Mar 2020 12:29:05 -0700 (PDT) Received: from rani.riverdale.lan ([2001:470:1f07:5f3::b55f]) by smtp.gmail.com with ESMTPSA id x89sm2292649qtd.43.2020.03.19.12.29.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Mar 2020 12:29:05 -0700 (PDT) From: Arvind Sankar To: Ard Biesheuvel Cc: linux-efi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 10/14] efi/gop: Add prototypes for query_mode and set_mode Date: Thu, 19 Mar 2020 15:28:51 -0400 Message-Id: <20200319192855.29876-11-nivedita@alum.mit.edu> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20200319192855.29876-1-nivedita@alum.mit.edu> References: <20200319192855.29876-1-nivedita@alum.mit.edu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add prototypes and argmap for the Graphics Output Protocol's QueryMode and SetMode functions. Signed-off-by: Arvind Sankar --- arch/x86/include/asm/efi.h | 4 ++++ drivers/firmware/efi/libstub/efistub.h | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/arch/x86/include/asm/efi.h b/arch/x86/include/asm/efi.h index cdcf48d52a12..781170d36f50 100644 --- a/arch/x86/include/asm/efi.h +++ b/arch/x86/include/asm/efi.h @@ -305,6 +305,10 @@ static inline u32 efi64_convert_status(efi_status_t status) #define __efi64_argmap_load_file(protocol, path, policy, bufsize, buf) \ ((protocol), (path), (policy), efi64_zero_upper(bufsize), (buf)) +/* Graphics Output Protocol */ +#define __efi64_argmap_query_mode(gop, mode, size, info) \ + ((gop), (mode), efi64_zero_upper(size), efi64_zero_upper(info)) + /* * The macros below handle the plumbing for the argument mapping. To add a * mapping for a specific EFI method, simply define a macro diff --git a/drivers/firmware/efi/libstub/efistub.h b/drivers/firmware/efi/libstub/efistub.h index cc90a748bcf0..c400fd88fe38 100644 --- a/drivers/firmware/efi/libstub/efistub.h +++ b/drivers/firmware/efi/libstub/efistub.h @@ -298,8 +298,10 @@ typedef union efi_graphics_output_protocol efi_graphics_output_protocol_t; union efi_graphics_output_protocol { struct { - void *query_mode; - void *set_mode; + efi_status_t (__efiapi *query_mode)(efi_graphics_output_protocol_t *, + u32, unsigned long *, + efi_graphics_output_mode_info_t **); + efi_status_t (__efiapi *set_mode) (efi_graphics_output_protocol_t *, u32); void *blt; efi_graphics_output_protocol_mode_t *mode; }; -- 2.24.1