Skip to content

Commit

Permalink
drivers: rkflash: Update to SFTL version: 5.0.57 20210712
Browse files Browse the repository at this point in the history
Calling uaccess ops from ftl.S will link to arm_copy_from_user directly
and result in page domain fault. So I add it to c code.

[   48.045091] Unhandled fault: page domain fault (0x01b) at 0xbe822790
[   48.054152] pgd = cda78000
[   48.056867] [be822790] *pgd=6da16835, *pte=61b5175f, *ppte=61b51c7f
[   48.063213] Internal error: : 1b [#1] SMP ARM
[   48.067570] Modules linked in: 8821cs
[   48.071292] CPU: 1 PID: 595 Comm: vendor_storage Not tainted 4.4.194 #117
[   48.078083] Hardware name: Generic DT based system
[   48.082884] task: cd0c6580 task.stack: cda94000
[   48.087432] PC is at arm_copy_from_user+0xc8/0x3d8
[   48.092230] LR is at rk_sftl_vendor_storage_ioctl+0x78/0x20c

Change-Id: I1edc9167ac027de3b06768cf718e706074233ae4
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
  • Loading branch information
Jon Lin committed Jul 12, 2022
1 parent b9e3ad9 commit 77e8a67
Show file tree
Hide file tree
Showing 3 changed files with 187 additions and 241 deletions.
2 changes: 2 additions & 0 deletions drivers/rkflash/rk_sftl.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ void *ftl_memset(void *s, int c, unsigned int n);
void *ftl_memcpy(void *pv_to,
const void *pv_from,
unsigned int size);
unsigned long ftl_copy_from_user(void *to, const void __user *from, unsigned long n);
unsigned long ftl_copy_to_user(void __user *to, const void *from, unsigned long n);

/*
* Function that needs to be defined
Expand Down
Loading

0 comments on commit 77e8a67

Please sign in to comment.