All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: HATAYAMA Daisuke <d.hatayama@jp.fujitsu.com>, grub-devel@gnu.org
Cc: lersek@redhat.com, glin@suse.com
Subject: Re: [PATCH] efinet: disable MNP background polling
Date: Thu, 1 Oct 2015 20:40:24 +0300	[thread overview]
Message-ID: <560D7008.1050004@gmail.com> (raw)
In-Reply-To: <20151001.182655.371384337.d.hatayama@jp.fujitsu.com>

01.10.2015 12:26, HATAYAMA Daisuke пишет:
>
> Actually, PXE boot fails on Fujitsu PRIMEQUEST 2000 series now.
>

Could you give more details what fails here? GRUB is not loaded or GRUB 
fails to load its files or image chainloaded by GRUB fails?

>
> diff --git a/grub-core/net/drivers/efi/efinet.c b/grub-core/net/drivers/efi/efinet.c
> index c9af01c..a506ab3 100644
> --- a/grub-core/net/drivers/efi/efinet.c
> +++ b/grub-core/net/drivers/efi/efinet.c
> @@ -29,6 +29,7 @@ GRUB_MOD_LICENSE ("GPLv3+");
>   /* GUID.  */
>   static grub_efi_guid_t net_io_guid = GRUB_EFI_SIMPLE_NETWORK_GUID;
>   static grub_efi_guid_t pxe_io_guid = GRUB_EFI_PXE_GUID;
> +static grub_efi_guid_t mnp_io_guid = GRUB_EFI_MANAGED_NETWORK_GUID;
>
>   static grub_err_t
>   send_card_buffer (struct grub_net_card *dev,
> @@ -269,6 +270,9 @@ grub_efi_net_config_real (grub_efi_handle_t hnd, char **device,
>       grub_efi_device_path_t *cdp;
>       struct grub_efi_pxe *pxe;
>       struct grub_efi_pxe_mode *pxe_mode;
> +    grub_efi_managed_network_t *mnp;
> +    struct grub_efi_managed_network_config_data m;
> +    struct grub_efi_simple_network_mode s;
>       if (card->driver != &efidriver)
>         continue;
>       cdp = grub_efi_get_device_path (card->efi_handle);
> @@ -312,6 +316,16 @@ grub_efi_net_config_real (grub_efi_handle_t hnd, char **device,
>   				    &pxe_mode->dhcp_ack,
>   				    sizeof (pxe_mode->dhcp_ack),
>   				    1, device, path);
> +
> +    mnp = grub_efi_open_protocol (card->efi_handle, &mnp_io_guid,
> +				  GRUB_EFI_OPEN_PROTOCOL_GET_PROTOCOL);
> +
> +    if (mnp
> +	&& efi_call_3 (mnp->get_mode_data, mnp, &m, &s) == GRUB_EFI_SUCCESS) {
> +      m.disable_background_polling = 1;
> +      efi_call_2 (mnp->configure, mnp, &m);
> +    }
> +

That's not going to work, sorry. As Laszlo already explained, base card 
does not have MNP protocol as all. MNP is bound to child nodes and 
configuration is per-child so you would need to iterate through all of them.




  parent reply	other threads:[~2015-10-08  9:32 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-01  9:26 [PATCH] efinet: disable MNP background polling HATAYAMA Daisuke
2015-10-01 11:50 ` [grub PATCH] " Laszlo Ersek
2015-10-01 17:53   ` Andrei Borzenkov
2015-10-01 22:04     ` Yinghai Lu
2015-10-02  3:48       ` Andrei Borzenkov
2015-10-09 10:15     ` HATAYAMA Daisuke
2015-10-13 22:11     ` Daniel Kiper
2015-10-13 22:23       ` Laszlo Ersek
2015-10-14  1:01       ` Yinghai Lu
2015-10-14  7:00         ` Andrei Borzenkov
2015-10-09 10:10   ` HATAYAMA Daisuke
2015-10-09 11:19     ` Laszlo Ersek
2015-10-13 21:49   ` Daniel Kiper
2015-10-13 22:21     ` Laszlo Ersek
2015-10-13 22:56       ` Daniel Kiper
2015-10-14  0:43       ` Seth Goldberg
2015-10-14  5:19       ` [edk2] " Ye, Ting
2015-10-14  5:57         ` Andrei Borzenkov
2015-10-14  6:15           ` Ye, Ting
2015-10-14  6:58             ` Andrei Borzenkov
2015-10-14  8:00               ` Ye, Ting
2015-10-14 17:52                 ` Andrei Borzenkov
2015-10-14 11:08         ` Daniel Kiper
2015-10-14 15:39           ` Seth Goldberg
2015-10-15  2:11             ` Ye, Ting
2015-10-15 18:14               ` Laszlo Ersek
2015-10-15 22:33                 ` Andrew Fish
2015-10-15 22:57                   ` Michael Brown
2015-10-15 23:38                   ` Laszlo Ersek
2015-10-29 14:47             ` Vladimir 'φ-coder/phcoder' Serbinenko
2015-10-01 17:40 ` Andrei Borzenkov [this message]
2015-10-09 10:30   ` [PATCH] " HATAYAMA Daisuke

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=560D7008.1050004@gmail.com \
    --to=arvidjaar@gmail.com \
    --cc=d.hatayama@jp.fujitsu.com \
    --cc=glin@suse.com \
    --cc=grub-devel@gnu.org \
    --cc=lersek@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.