oe-chipsec.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Li Qiang <liq3ea@gmail.com>
To: chipsec@lists.01.org
Subject: How to read/write SPI flash descriptor
Date: Thu, 09 May 2019 15:31:11 +0800	[thread overview]
Message-ID: <CAKXe6SKOfuyB3jOvhMFzd617Wxj0R-yF=HSeUtoA5MWYA5-+YA@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 704 bytes --]

Hello all,

I used chipsec to evaluate my hardware.

And I got following report:

[-] Software has write access to SPI flash descriptor
[-] FAILED: SPI flash permissions allow SW to write flash descriptor

I look at the chipsec source code and find that this is read from frap
register(SPIBAR + 50h).
However I can't find the spec how to read the SPI flash descriptor itself.
I find some code from flashrom:
https://github.com/flashrom/flashrom/blob/db7482bb72035fab8386226d1720cde09e0c700e/ich_descriptors.c

It reads SPI flash descriptor using MMIO, but also I don't know how to
write it.(it has no effect when write to the same register with read).

Any hints?

Thanks,
Li Qiang

[-- Attachment #2: attachment.html --]
[-- Type: text/html, Size: 1134 bytes --]

             reply	other threads:[~2019-05-09  7:31 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-09  7:31 Li Qiang [this message]
2022-04-15 11:57 ` How to read/write SPI flash descriptor ericc6727
2022-04-15 11:57 ` ericc6727
2022-06-30 11:01 ` beausconce
2022-08-26  9:37 ` jacobsmithooopp122

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='CAKXe6SKOfuyB3jOvhMFzd617Wxj0R-yF=HSeUtoA5MWYA5-+YA@mail.gmail.com' \
    --to=liq3ea@gmail.com \
    --cc=chipsec@lists.01.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).