.
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/interrupt.c | 4
1 file changed, 4 insertions(+)
diff --git a/drivers/misc/mei/interrupt.c b/drivers/misc/mei/interrupt.c
index c418d7888994..64b568a0268d 100644
--- a/drivers/misc/mei/interrupt.c
+++ b
From: Alexander Kuleshov
Signed-off-by: Alexander Kuleshov
Signed-off-by: Tomas Winkler
---
V2: fixed author address
V3: resend
drivers/misc/mei/debugfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/misc/mei/debugfs.c b/drivers/misc/mei/debugfs.c
index
0010
Cc:
Reported-by: Heiner Kallweit
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/hbm.c | 9 ++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/misc/mei/hbm.c b/drivers/misc/mei/hbm.c
index f15d44bda28e
spend/resume.
This patch cannot be really separated from the locality fix.
Fixes: 888d867df441 (tpm: cmd_ready command can be issued only after granting
locality)
Cc: sta...@vger.kernel.org
Fixes: 888d867df441 (tpm: cmd_ready command can be issued only after granting
locality)
Signed-off-by:
From: Alexander Usyskin
Add optional timeout to internal bus recv function to
enable break out of internal flows in case of no answer from FW.
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/bus-fixup.c | 2 +-
drivers/misc/mei/bus.c | 36
different FW components.
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
Documentation/ABI/testing/sysfs-class-mei | 11
drivers/misc/mei/bus-fixup.c | 86 ---
drivers/misc/mei/main.c | 30 ++-
drivers/misc/mei
/0x80
pci_device_shutdown+0x34/0x60
kernel_restart+0x0e/0x30
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=200455
Fixes: 'c110cdb17148 ("mei: bus: make a client pointer always available")'
Cc: 4.10+
Tested-by: Georg Müller
Signed-off-by: Tomas Winkler
---
drivers/misc/m
currently only happens
on platforms with AMT watchdog enabled that systemd holds.
Both patches bellow should be applied.
Tomas Winkler (2):
mei: bus: fix hw module get/put balance
mei: bus: need to unlink client before freeing
drivers/misc/mei/bus.c | 12 +---
1 file changed, 5
200455
Tested-by: Georg Müller
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/bus.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/misc/mei/bus.c b/drivers/misc/mei/bus.c
index 7bba62a72921..13c6c9a2248a 100644
--- a/drivers/misc/mei/bus.c
+++ b/drivers/misc/mei/bu
On Sat, Aug 11, 2018 at 12:45 AM Jarkko Sakkinen
wrote:
>
> On Fri, Aug 10, 2018 at 07:57:35PM +0300, Jarkko Sakkinen wrote:
> > On Tue, Aug 07, 2018 at 02:43:10PM -0400, Harlan Lieberman-Berg wrote:
> > > (Resending as it seems to have been spamfiltered out from the ml;
> > > sorry Peter, Jarkko
ire re-reading buf->size
either), so the fix is to simply revert the change, and return len, as
before.
Fixes: 98e70866aacb ("mei: add support for variable length mei headers.")
CC: Arnd Bergmann
CC: Greg Kroah-Hartman
Signed-off-by: John Hubbard
Signed-off-by: Tomas Winkler
---
V2
that fits
into the HW ring while a packet that would require
fragmentation is faster to send via the DMA ring.
Alexander Usyskin (3):
mei: define dma ring buffer sizes for PCH12 HW and newer
mei: bump hbm version to 2.1
mei: me: mark CNP devices as having dma support
Tomas Winkler (9):
mei
Add dma_ring bit in the mei message header for conveying
that the message data itself are on the dma ring.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/client.c | 1 +
drivers/misc/mei/hbm.c | 1 +
drivers/misc/mei/hw.h | 16
Allocate DMA ring buffers from managed coherent memory.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/Makefile | 1 +
drivers/misc/mei/dma-ring.c | 103
drivers/misc/mei/hw-me.c| 6 +++
drivers/misc/mei
mei_data2slots() converts data length directly to the slots.
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/client.c| 31 ++-
drivers/misc/mei/hbm.c | 30 ++
drivers/misc/mei/hw-me.c | 34
finally a Control block where the pointers for the both
circular buffers are managed.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/hw.h | 49 +
1 file changed, 49 insertions(+)
diff --git a/drivers/misc/mei
Implement circular buffer protocol over receive dma
buffer. Add extension to the mei message header that holds
length of the buffer on the dma buffer.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/client.c| 2 +-
drivers/misc/mei/dma-ring.c | 63
Only a firmware with version 2.1 and above supports dma ring feature.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/debugfs.c | 2 ++
drivers/misc/mei/hbm.c | 6 ++
drivers/misc/mei/hw.h | 6 ++
drivers/misc/mei/mei_dev.h | 2 ++
4 files
on the TX
DMA circular buffer and later, returns the number of empty slots on the
TX DMA circular buffer.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/client.c | 56 ++--
drivers/misc/mei/dma-ring.c | 91
DMA ring is allocated upon HBM handshake and the ring parameters are set
via dedicated HBM_DMA_SETUP request command. The firmware will perform
its setup and respond with a status. On failure the DMA buffers are
released.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
The DMA ring control block contains write and read
indices for host and device circular buffers.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/dma-ring.c | 21 +
drivers/misc/mei/hbm.c | 2 ++
drivers/misc/mei/hw.h | 23
From: Alexander Usyskin
Bump HBM version to 2.1 to indicate DMA transfer support.
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/hw.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/misc/mei/hw.h b/drivers/misc/mei/hw.h
index
From: Alexander Usyskin
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/pci-me.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/misc/mei/pci-me.c b/drivers/misc/mei/pci-me.c
index ea4e152270a3..73ace2d59dea 100644
--- a
From: Alexander Usyskin
Define dma ring buffer sizes for PCH12 (CLN HW and newer)
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/hw-me.c | 13 +
drivers/misc/mei/hw-me.h | 4
2 files changed, 17 insertions(+)
diff --git a/drivers/misc
The host buffer depth is hardware specific so it's better to
handle it inside the me and txe hw modules. In me the depth
is read from register in txe it's a constant number.
The value is now retrieved via mei_hbuf_depth accessor,
while it replaces mei_hbuf_max_len.
Signed-off-by: Tom
Cleanup conversions between slots and data.
Define MEI_SLOT_SIZE instead of using 4 or sizeof(u32) across
the source code.
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/client.c | 2 +-
drivers/misc/mei/hw-me.c | 8
drivers/misc/mei/hw-txe.c | 8
drivers/misc/mei
Wrap the mei header boilerplate initialization code in
mei_msg_hdr_init function. On the way remove 'completed'
field from mei_cl_cb structure as this information
is already included in the header and is local to particular
fragment.
Signed-off-by: Tomas Winkler
---
drivers/misc/me
: comparison between signed and
unsigned integer expressions [-Wsign-compare]
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/client.c | 22 +++---
drivers/misc/mei/client.h | 2 +-
drivers/misc/mei/main.c | 10 +-
3 files changed, 17 insertions(+), 17 deletions(-)
diff
expressions [-Wsign-compare]
drivers/misc/mei/hw-txe.c:744:16: warning: comparison between signed and
unsigned integer expressions [-Wsign-compare]
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/bus-fixup.c | 2 +-
drivers/misc/mei/hw-me.c | 2 +-
drivers/misc/mei/hw-txe.c| 2 +-
3 files
st
in comparison to suppress singn-compare warning.
Reported-by: Dan Carpenter
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/client.c| 22 --
drivers/misc/mei/hw-me.c | 5 -
drivers/misc/mei/hw-txe.c| 2 +-
drivers/misc/mei/interrupt.c | 15 +++
4
Add more type conversion issues.
The first one in also address the type promotion bug,
as reported by Dan Carpenter. The particular error should
not really happen unless something is completely wrong, so no urge
to merging them into stable.
Tomas Winkler (3):
mei: check for error returned from
("mei: bus: type promotion bug in mei_fwver()")
Now it is possible to suppress the warning, by adding proper
casting to move out of radar.
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/bus-fixup.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mi
citly.
This patch exposes cmd_read/go_idle via tpm class ops and removes
runtime pm support as it is not used by any driver.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 15 ++---
drivers/char/tpm/tpm_crb.c | 69 +---
include/
idle handshake has completed, this requires that
go_idle has to poll for the completion.
The issue is only visible on devices that support multiple localities.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 12 ++---
drivers/char/tpm/tpm_crb.c
TPM2_CC_Create(0x153) and TPM2_CC_CreatePrimary (0x131) involve generation
of crypto keys which can be a computationally intensive task.
The timeout is set to 3min.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 4
drivers/char/tpm/tpm.h | 27
goIdle and locality relinquish.
The second patch removes cmdRead/goIdle handshake from runtime_pm as it's
rather a part of TPM2 protocol then true device power management,
and on device it's no longer optional.
Tomas Winkler (2):
tpm: cmd_ready command can be issued only after grantin
idle handshake has completed, this requires that
go_idle has to poll for the completion and as well locality
relinquish has to poll for completion so it is not overrriden
in back to back commands flow.
The issue is only visible on devices that support multiple localities.
Signed-off-by: Tomas Wi
citly.
This patch exposes cmd_read/go_idle via tpm class ops and removes
runtime pm support as it is not used by any driver.
Signed-off-by: Tomas Winkler
---
V2: resent
drivers/char/tpm/tpm-interface.c | 15 ++---
drivers/char/tpm/tpm_crb.c
TPM2_CC_Create(0x153) and TPM2_CC_CreatePrimary (0x131) involve generation
of crypto keys which can be a computationally intensive task.
The timeout is set to 3min.
Signed-off-by: Tomas Winkler
---
V2: resent
drivers/char/tpm/tpm-interface.c | 4
drivers/char/tpm/tpm.h | 27
Factor out tpm_get_timeouts into tpm2_get_timeouts
and tpm1_get_timeouts.
Signed-off-by: Tomas Winkler
---
V2: Rebase
V3: 1. Fix typo tmp->tpm
2. Fix sparse WARNING: line over 80 characters
drivers/char/tpm/tpm-interface.c | 127 ++-
drivers/char/
Add new function tpm2_validate_command to tpm2-space.c
that wraps up open coded functionality from tpm_validate_command.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 31 ++-
drivers/char/tpm/tpm.h | 1 +
drivers/char/tpm/tpm2-cmd.c
tpm manual startup is used only from within tpm1 or tpm2
code, hence remove tpm_startup function from tpm-interface.c
and add two static functions implementations tpm1_startup
and tpm2_startup into to tpm1-cmd.c and tpm2-cmd.c respectively.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm
Move tpm1_pcr_extend to tpm1-cmd.c and remove
unused pcrextend_header structure.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 28
drivers/char/tpm/tpm.h | 2 ++
drivers/char/tpm/tpm1-cmd.c | 23 +++
3 files
Move the tmp1 selftest code functions to tpm1-cmd.c
and adjust callers to use the new function names.
1. tpm_pcr_read_dev to tpm1_pcr_read_dev
2. tpm_continue_selftest to tpm1_continue_selftest
3. tpm_do_selftest to tpm1_do_selftest
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/st33zp24
Factor out tpm1 suspend flow from tpm-interface.c into a new function
tpm1_pm_suspend in tpm1-cmd.c
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 55
drivers/char/tpm/tpm.h | 1 +
drivers/char/tpm/tpm1-cmd.c | 54
1. Move tpm_getcap to tpm1-cmd. Rename the function to tpm1_getcap.
2. Remove unused tpm_getcap_header with unused constant
as this functionality is already implemented using tpm_buf construct.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 47
Add tpm2_pcr_extend function to tpm2-cmd.c with signature required
by tpm-interface.c. It wraps the original open code
implementation. The original original tpm2_pcr_extend function
is renamed and made static, called only from new tpm2_pcr_extend.
Signed-off-by: Tomas Winkler
---
drivers/char
pletely
2. Fix notorious typo tmp -> tpm, in some patches
Tomas Winkler (8):
tpm: move tpm1_pcr_extend to tpm1-cmd.c
tpm: move tpm_getcap to tpm1-cmd.c
tpm: factor out tpm1_get_random into tpm1-cmd.c
tpm: move tpm1 selftest code from tpm-interface tpm1-cmd.c
tpm: factor out tpm1
Factor out get random implementation from tpm-interface.c
into tpm1_get_random function in tpm1-cmd.c.
No functional changes.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 56
drivers/char/tpm/tpm.h | 2 ++
drivers/char
-by: Tomas Winkler
---
V2: Add more explanation to the commit message.
V3: Rename TPM_DURATION_MAX to TPM_NUM_DURATIONS.
drivers/char/tpm/tpm-interface.c | 3 +++
drivers/char/tpm/tpm.h | 28 ++--
drivers/char/tpm/tpm2-cmd.c | 8 +---
3 files changed, 26
Add convenient wrapper for ordinal duration computation
to remove boiler plate if else statement over TPM2.
if (chip->flags & TPM_CHIP_FLAG_TPM2)
tpm2_calc_ordinal_duration(chip, ordinal);
else
tpm1_calc_ordinal_duration(chip, ordinal);
Signed-off-by: Tomas Winkler
---
Make the tpm Makefile a bit more in order by putting
objects in one column and group together tpm2 modules
Prefer tpm-objs += instead of tpm-y += notation.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/Makefile | 14 +++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff
PRC extend and get capability were reimplemented using
tpm_buf_ interface and the dangling tpm_input_headers can be dropped.
together with now unused constants.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 16 +---
1 file changed, 1 insertion(+), 15 deletions
1. TPM2_CC_LAST has moved from 182 to 193
2. Convert tpm2_ordinal_duration from an array into a switch statement,
as there are not so many commands that require special duration
relative to a number of commands.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm.h | 41
Factor out tpm_get_timeouts into tpm2_get_timeouts
and tpm1_get_timeouts.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 127 ++-
drivers/char/tpm/tpm.h | 5 +-
drivers/char/tpm/tpm1-cmd.c | 107
TPM2_CC_Create(0x153) and TPM2_CC_CreatePrimary (0x131) involve generation
of crypto keys which can be a computationally intensive task.
The timeout is set to 3min.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 3 +++
drivers/char/tpm/tpm.h | 28
Factor out tpm1.2 commands calculation into tpm1-cmd.c file.
and change the prefix from tpm_ to tpm1_.
No functional change is done here.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/Makefile| 1 +
drivers/char/tpm/st33zp24/st33zp24.c | 2 +-
drivers/char/tpm/tpm
added, to not stall too long on regular commands failures.
Second is to define timeouts for new tpm2 commands
defined in TCG 1.36 spec.
Last, is to factor out tpm1.2 commands out of tpm-interface.c
Tomas Winkler (6):
tpm: sort objects in the Makefile
tpm: factor out tpm 1.2 duration calculation
Factor out tpm_get_timeouts into tpm2_get_timeouts
and tpm1_get_timeouts.
Signed-off-by: Tomas Winkler
---
V2: Rebase.
drivers/char/tpm/tpm-interface.c | 127 ++-
drivers/char/tpm/tpm.h | 5 +-
drivers/char/tpm/tpm1-cmd.c | 107
1. TPM2_CC_LAST has moved from 182 to 193
2. Convert tpm2_ordinal_duration from an array into a switch statement,
as there are not so many commands that require special duration
relative to a number of commands.
Signed-off-by: Tomas Winkler
---
V2: Rebase.
drivers/char/tpm/tpm.h
Factor out tpm1.2 commands calculation into tpm1-cmd.c file.
and change the prefix from tpm_ to tpm1_.
No functional change is done here.
Signed-off-by: Tomas Winkler
---
V2: Rebase.
drivers/char/tpm/Makefile| 1 +
drivers/char/tpm/st33zp24/st33zp24.c | 2 +-
drivers/char/tpm
added, to not stall too long on regular commands failures.
Second is to define timeouts for new tpm2 commands
defined in TCG 1.36 spec.
Tomas Winkler (5):
tpm: sort objects in the Makefile
tpm: factor out tpm 1.2 duration calculation to tpm1-cmd.c
tpm2: add longer timeouts for creation commands
-by: Tomas Winkler
---
V2: add more explanation to the commit message.
drivers/char/tpm/tpm-interface.c | 3 +++
drivers/char/tpm/tpm.h | 28 ++--
drivers/char/tpm/tpm2-cmd.c | 8 +---
3 files changed, 26 insertions(+), 13 deletions(-)
diff --git a
Make the tpm Makefile a bit more in order by putting
objects in one column and group together tpm2 modules
Signed-off-by: Tomas Winkler
---
V2: 1. back to tpm-y notation
2. Partially sort files alphanumerically.
drivers/char/tpm/Makefile | 15 ---
1 file changed, 12 insertions
Move the tmp1 selftest code functions to tpm1-cmd.c
tpm_pcr_read_dev to tpm1_pcr_read_dev
tpm_continue_selftest to tpm1_continue_selftest
tpm_do_selftest to tpm1_do_selftest
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/st33zp24/st33zp24.c | 2 +-
drivers/char/tpm/tpm-interface.c
1. Move tpm_getcap to tpm1-cmd. Rename the function to tpm1_getcap.
2. Remove unsed tpm_getcap_header with unused constant
as the functionality is implemented using tpm_buf construct.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 47
Factor out get random implementation from tpm-interface.c
into tpm1_get_random function in tpm1-cmd.c.
No functional changes.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 56
drivers/char/tpm/tpm.h | 2 ++
drivers/char
Move tpm 1.x implementation to tpm1-cmd.c similarly to tpm2-cmd.c
This is work in progress of possible dropping compiling out
one tpm 1.x or tpm 2.x in case not needed on a target platform.
Tomas Winkler (4):
tmp: move tpm1_pcr_extend to tpm1-cmd.c
tmp: move tpm_getcap to tpm1-cmd.c
tmp
Move tpm1_pcr_extend to tpm1-cmd.c and remove
unused pcrextend_header structure.
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm-interface.c | 28
drivers/char/tpm/tpm.h | 2 ++
drivers/char/tpm/tpm1-cmd.c | 23 +++
3 files
use __le64 annotated variable for response buffer address as this is
read in little endian format form the register.
This suppresses sparse warning
drivers/char/tpm/tpm_crb.c:558:18: warning: cast to restricted __le64
Signed-off-by: Tomas Winkler
---
V2: Add more info into the commit message
/ufshcd.c:356:9:expected void const *buf
drivers/scsi/ufs/ufshcd.c:356:9:got void [noderef] *mmio_base
Signed-off-by: Tomas Winkler
---
drivers/scsi/ufs/ufs-qcom.c | 21 ++---
drivers/scsi/ufs/ufshcd.c | 35 ---
drivers/scsi/ufs/ufshcd.h
M2 protocol and should be called explicitly.
This patch exposes cmd_read/go_idle via tpm class ops and removes
runtime pm support as it is not used by any driver.
tpm_crb no longer needs own power saving functions and can drop using
tpm_pm_suspend/resume.
Signed-off-by: Tomas Winkler
---
V2-3:re
: cmd_ready command can be issued only after granting
locality)
Signed-off-by: Tomas Winkler
---
drivers/char/tpm/tpm_crb.c | 10 +++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/drivers/char/tpm/tpm_crb.c b/drivers/char/tpm/tpm_crb.c
index 7f78482cd157..34fbc6cb097b 100644
05:30: warning: invalid assignment: |=
drivers/misc/mei/main.c:605:30:left side has type restricted __poll_t
drivers/misc/mei/main.c:605:30:right side has type int
Cc: #v4.17+
Fixes: 'commit af336cabe083 ("mei: limit the number of queued writes")'
Signed-off-by: Toma
struct tpm_input_header pcrextend_header = {
^~~~
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
---
V2-V3: Rebase
V4: Remove defines.
V5: Resend.
drivers/char/tpm/tpm-interface.c | 28
drivers/char/tpm
x27;s platforms.
Tomas Winkler (21):
tpm2: add new tpm2 commands according to TCG 1.36
tpm: sort objects in the Makefile
tpm: factor out tpm 1.x duration calculation to tpm1-cmd.c
tpm: add tpm_calc_ordinal_duration() wrapper
tpm: factor out tpm_get_timeouts()
tpm: move tpm1_pcr_exte
used [-Wunused-const-variable=]
static const struct tpm_input_header tpm_getcap_header = {
^
3. Drop unused TPM_DIGEST_SIZE. It's already defined in
include/linux/tpm.h
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
Test
1. Use tpm_buf in tpm1_get_random()
2. Fix comment in tpm_get_random() so it is clear that
the function is expected to return number of random bytes.
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
Tested-by: Jarkko Sakkinen
---
V3: New in the series.
V4: Resend.
V5: A small
Factor out TPM 1.x suspend flow from tpm-interface.c into a new function
tpm1_pm_suspend() in tpm1-cmd.c
Signed-off-by: Tomas Winkler
---
V2-V3: Rebase
V4: 1. Add kdoc for tpm1_pm_suspend().
2. Fix commit message.
V5: Adjust the kdoc to the new standard.
drivers/char/tpm/tpm-interface.c
kdoc comments for tpm2_calc_ordinal_duration().
Signed-off-by: Tomas Winkler
Tested-by: Jarkko Sakkinen
---
V2-V3: Rebase.
V4: 1. Fix kdoc
2. Rename tpm2_ordinal_duration() to tpm2_ordinal_duration_index()
3. Move the two functions close to each other in the file.
V5: Adjust the kdoc to
Remove unneeded semicolon in tpm2_map_response_header()
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
---
V3: New in the series.
V4-V5: Resend.
drivers/char/tpm/tpm2-space.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/char/tpm/tpm2-space.c b
t;TSC_MAX_ORDINAL" is not used
[-Wunused-macros]
tpm-interface.c:38:0: warning: macro "TPM_CONNECTION_COMMAND" is not used
[-Wunused-macros]
Fixes: f72864300139 ("tpm_tis: further simplify calculation of ordinal
duration")
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko
Make the tpm Makefile a bit more in order by putting
objects in one column.
Signed-off-by: Tomas Winkler
Tested-by: Jarkko Sakkinen
Reviewed-by: Jarkko Sakkinen
---
V2: 1. back to tpm-y notation
2. Partially sort files alphanumerically.
V3: Rebase
V4: Remove redunant sentence in commit
TPM manual startup is used only from within TPM 1.x or TPM 2.x
code, hence remove tpm_startup() function from tpm-interface.c
and add two static functions implementations tpm1_startup()
and tpm2_startup() into to tpm1-cmd.c and tpm2-cmd.c respectively.
Signed-off-by: Tomas Winkler
Tested-by
Reimplement tpm1_continue_selftest() using tpm_buf structure.
This is the last command using the old tpm_cmd_t structure
and now the structure can be removed.
Cc: Nayna Jain
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
Tested-by: Jarkko Sakkinen
---
V3: New in the series.
V4
Implement tpm1_pcr_read_dev() using tpm_buf and remove
now unneeded structures from tpm.h
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
Tested-by: Jarkko Sakkinen
---
V3: New in the series.
V4-V5: Resend.
drivers/char/tpm/tpm.h | 18 ++
drivers/char/tpm/tpm1
PCR related
functions.
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
---
V3: New in the series.
V4: Separate unrelated change to another patches.
V5: Fix the commit message.
drivers/char/tpm/tpm-interface.c| 6 +++---
drivers/char/tpm/tpm-sysfs.c| 2 +-
drivers/char/tpm
in __tpm2_pcr_extend()
tpm2-cmd.c:251:16: warning: comparison between signed and unsigned integer
expressions [-Wsign-compare]
tpm2-cmd.c:252:17: warning: comparison between signed and unsigned integer
expressions [-Wsign-compare]
Signed-off-by: Tomas Winkler
---
V3: Fix the commit message.
V4: 1
In tpm1_pm_suspend() function reimplement,
TPM_ORD_SAVESTATE comamnd using tpm_buf.
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
Tested-by: Jarkko Sakkinen
---
V3: New in the series.
V4-V5: Resend
drivers/char/tpm/tpm1-cmd.c | 22 --
1 file changed, 12
Add wrapper tpm_auto_startup() to tpm-interface.c
instead of open coded decision between TPM 1.x and TPM 2.x
in tpm-chip.c
Signed-off-by: Tomas Winkler
Tested-by: Jarkko Sakkinen
---
V3: New in the series.
V4: Fix the commit message.
V5: Resend.
drivers/char/tpm/tpm-chip.c | 11
Rename tpm1_pcr_read_dev to tpm1_pcr_read() to match
the counterpart tpm2_pcr_read().
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
---
V4: New in the series
V5: Resend.
drivers/char/tpm/tpm-interface.c | 2 +-
drivers/char/tpm/tpm-sysfs.c | 2 +-
drivers/char/tpm/tpm.h
Factor out tpm_get_timeouts() into tpm2_get_timeouts()
and tpm1_get_timeouts()
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkinen
Tested-by: Jarkko Sakkinen
---
V2-V3: Rebase
V4: Fix the commit message.
V5: Resend.
drivers/char/tpm/tpm-interface.c | 127
Move the tpm1 selftest code functions to tpm1-cmd.c
and adjust callers to use the new function names.
1. tpm_pcr_read_dev() to tpm1_pcr_read_dev().
2. tpm_continue_selftest() to tpm1_continue_selftest().
3. tpm_do_selftest() to tpm1_do_selftest()
Signed-off-by: Tomas Winkler
Tested-by: Jarkko
Factor out get random implementation from tpm-interface.c
into tpm1_get_random function in tpm1-cmd.c.
No functional changes.
Signed-off-by: Tomas Winkler
Reviewed-by: Jarkko Sakkine
---
V2-V3: Rebase
V4-V5: Resend
drivers/char/tpm/tpm-interface.c | 58
Add convenient wrapper for ordinal duration computation
to remove boiler plate if else statement over TPM2.
if (chip->flags & TPM_CHIP_FLAG_TPM2)
tpm2_calc_ordinal_duration(chip, ordinal);
else
tpm1_calc_ordinal_duration(chip, ordinal);
Signed-off-by: Tomas Winkler
Revi
Factor out TPM 1.x commands calculation into tpm1-cmd.c file.
and change the prefix from tpm_ to tpm1_.
No functional change is done here.
Signed-off-by: Tomas Winkler
Tested-by: Jarkko Sakkinen
---
V2-V3: Rebase
V4: 1. Remove the licence statement it's already covered by SPDX.
2. Add
Add /* fallthrough */ annotation, to eliminate compilation warning:
warning: this statement may fall through [-Wimplicit-fallthrough=]
Signed-off-by: Tomas Winkler
---
drivers/scsi/ufs/ufshcd.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs
://www.kernel.org/doc/html/latest/doc-guide/kernel-doc.html
Alexander Usyskin (2):
mei: bump hbm version to 2.1
mei: me: mark CNP devices as having dma support
Tomas Winkler (5):
mei: dma ring buffers allocation
mei: hbm: setup dma ring
mei: hw: add dma ring control block
mei: dma ring
From: Alexander Usyskin
Signed-off-by: Alexander Usyskin
Signed-off-by: Tomas Winkler
---
drivers/misc/mei/pci-me.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/misc/mei/pci-me.c b/drivers/misc/mei/pci-me.c
index ea4e152270a3..73ace2d59dea 100644
--- a
Allocate DMA ring buffers from managed coherent memory.
Signed-off-by: Tomas Winkler
Signed-off-by: Alexander Usyskin
---
drivers/misc/mei/Makefile | 1 +
drivers/misc/mei/dma-ring.c | 99 +
drivers/misc/mei/hw-me.c| 6 +++
drivers/misc/mei/mei_dev.h
301 - 400 of 1346 matches
Mail list logo