BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mangoh-drivers
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
mangoh-drivers
Commits
fc53eabf
Unverified
Commit
fc53eabf
authored
Mar 21, 2019
by
David Frey
Committed by
GitHub
Mar 21, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #26 from nxthongbk/cleanup_driver
ws_eink: clean up resource by free memory and cleanup deferred io
parents
f94500f6
0a1e13ea
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
10 deletions
+5
-10
fb_waveshare_eink.c
...l/waveshare_eink/linux_kernel_modules/fb_waveshare_eink.c
+5
-10
No files found.
experimental/waveshare_eink/linux_kernel_modules/fb_waveshare_eink.c
View file @
fc53eabf
...
@@ -606,11 +606,11 @@ static int ws_eink_spi_probe(struct spi_device *spi)
...
@@ -606,11 +606,11 @@ static int ws_eink_spi_probe(struct spi_device *spi)
disp_init_fail:
disp_init_fail:
framebuffer_release
(
info
);
framebuffer_release
(
info
);
fbreg_fail:
fbreg_fail:
k
free
(
par
->
ssbuf
);
v
free
(
par
->
ssbuf
);
ssbuf_alloc_fail:
ssbuf_alloc_fail:
vfree
(
info
->
screen_base
);
vfree
(
info
->
screen_base
);
screen_base_fail:
screen_base_fail:
k
free
(
info
->
screen_base
);
v
free
(
info
->
screen_base
);
return
retval
;
return
retval
;
}
}
...
@@ -618,15 +618,10 @@ static int ws_eink_spi_remove(struct spi_device *spi)
...
@@ -618,15 +618,10 @@ static int ws_eink_spi_remove(struct spi_device *spi)
{
{
struct
fb_info
*
p
=
spi_get_drvdata
(
spi
);
struct
fb_info
*
p
=
spi_get_drvdata
(
spi
);
struct
ws_eink_fb_par
*
par
=
p
->
par
;
struct
ws_eink_fb_par
*
par
=
p
->
par
;
fb_deferred_io_cleanup
(
p
);
unregister_framebuffer
(
p
);
unregister_framebuffer
(
p
);
/*
vfree
(
p
->
screen_base
);
* TODO: Why is this necessary? It doesn't seem that there is a call to
vfree
(
par
->
ssbuf
);
* fb_alloc_cmap()
*/
fb_dealloc_cmap
(
&
p
->
cmap
);
iounmap
(
p
->
screen_base
);
kfree
(
p
->
screen_base
);
kfree
(
par
->
ssbuf
);
framebuffer_release
(
p
);
framebuffer_release
(
p
);
return
0
;
return
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment