mapping linux /dev/fb0 to DDR for displaying

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite












I want to write a linux driver which maps my specified memory address space to /dev/fb0.



the driver should be specified by what part of linux? drm or frame buffer or server X or somthing else? Which properties should I have in my driver?










share|improve this question



















  • 1




    As I recall, although I am going by memory only as the question has since been deleted, in an earlier incarnation of this question you said that with one kernel you could send output to your LCD screen with cat via a framebuffer. So it would seem from that that there already is a Linux driver for your device.
    – JdeBP
    Sep 11 at 8:53










  • @JdeBP yes you are right. I deleted my question in order to clarify what i am looking for. Although I got nearer to it by what is said. In fact I have a zynq board and an LCD that want to display desktop environment on it. LCD turns on at boot time but when startx calls, the LCD turns off and I can not display desktop environment.
    – Mojtaba Ahmadi
    Sep 11 at 12:26














up vote
1
down vote

favorite












I want to write a linux driver which maps my specified memory address space to /dev/fb0.



the driver should be specified by what part of linux? drm or frame buffer or server X or somthing else? Which properties should I have in my driver?










share|improve this question



















  • 1




    As I recall, although I am going by memory only as the question has since been deleted, in an earlier incarnation of this question you said that with one kernel you could send output to your LCD screen with cat via a framebuffer. So it would seem from that that there already is a Linux driver for your device.
    – JdeBP
    Sep 11 at 8:53










  • @JdeBP yes you are right. I deleted my question in order to clarify what i am looking for. Although I got nearer to it by what is said. In fact I have a zynq board and an LCD that want to display desktop environment on it. LCD turns on at boot time but when startx calls, the LCD turns off and I can not display desktop environment.
    – Mojtaba Ahmadi
    Sep 11 at 12:26












up vote
1
down vote

favorite









up vote
1
down vote

favorite











I want to write a linux driver which maps my specified memory address space to /dev/fb0.



the driver should be specified by what part of linux? drm or frame buffer or server X or somthing else? Which properties should I have in my driver?










share|improve this question















I want to write a linux driver which maps my specified memory address space to /dev/fb0.



the driver should be specified by what part of linux? drm or frame buffer or server X or somthing else? Which properties should I have in my driver?







drivers display x-server framebuffer drm






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Sep 11 at 7:40









Rui F Ribeiro

36.8k1273117




36.8k1273117










asked Sep 11 at 5:34









Mojtaba Ahmadi

12110




12110







  • 1




    As I recall, although I am going by memory only as the question has since been deleted, in an earlier incarnation of this question you said that with one kernel you could send output to your LCD screen with cat via a framebuffer. So it would seem from that that there already is a Linux driver for your device.
    – JdeBP
    Sep 11 at 8:53










  • @JdeBP yes you are right. I deleted my question in order to clarify what i am looking for. Although I got nearer to it by what is said. In fact I have a zynq board and an LCD that want to display desktop environment on it. LCD turns on at boot time but when startx calls, the LCD turns off and I can not display desktop environment.
    – Mojtaba Ahmadi
    Sep 11 at 12:26












  • 1




    As I recall, although I am going by memory only as the question has since been deleted, in an earlier incarnation of this question you said that with one kernel you could send output to your LCD screen with cat via a framebuffer. So it would seem from that that there already is a Linux driver for your device.
    – JdeBP
    Sep 11 at 8:53










  • @JdeBP yes you are right. I deleted my question in order to clarify what i am looking for. Although I got nearer to it by what is said. In fact I have a zynq board and an LCD that want to display desktop environment on it. LCD turns on at boot time but when startx calls, the LCD turns off and I can not display desktop environment.
    – Mojtaba Ahmadi
    Sep 11 at 12:26







1




1




As I recall, although I am going by memory only as the question has since been deleted, in an earlier incarnation of this question you said that with one kernel you could send output to your LCD screen with cat via a framebuffer. So it would seem from that that there already is a Linux driver for your device.
– JdeBP
Sep 11 at 8:53




As I recall, although I am going by memory only as the question has since been deleted, in an earlier incarnation of this question you said that with one kernel you could send output to your LCD screen with cat via a framebuffer. So it would seem from that that there already is a Linux driver for your device.
– JdeBP
Sep 11 at 8:53












@JdeBP yes you are right. I deleted my question in order to clarify what i am looking for. Although I got nearer to it by what is said. In fact I have a zynq board and an LCD that want to display desktop environment on it. LCD turns on at boot time but when startx calls, the LCD turns off and I can not display desktop environment.
– Mojtaba Ahmadi
Sep 11 at 12:26




@JdeBP yes you are right. I deleted my question in order to clarify what i am looking for. Although I got nearer to it by what is said. In fact I have a zynq board and an LCD that want to display desktop environment on it. LCD turns on at boot time but when startx calls, the LCD turns off and I can not display desktop environment.
– Mojtaba Ahmadi
Sep 11 at 12:26










1 Answer
1






active

oldest

votes

















up vote
2
down vote



accepted










The driver is a linux kernel module.



Download the source of the linux kernel, have a look at the code of the existing framebuffer drivers in drivers/video/fbdev (github here) and the documentation in Documentation/fb (github). Google for tutorials how to write kernel modules, practice with a simple module first.



Just mapping memory won't be enough, you'll have to implement a few ioctls.



Writing kernel drivers is not easy. If you have to ask this kind of questions (and you asked a lot in the past few days), you probably won't be able to do it.



X is a server for the X protocol. It can use hardware via the DRM kernel modules, and it can also use hardware via framebuffer drivers (with the fbdev X driver). Details about that are easy to find online, google. /dev/fb0 is a framebuffer device, so you don't need to concern yourself with X or DRM.






share|improve this answer




















  • thank you. I asked because answers were confusing and in different forums, different answers were given. and I was looking for simpler and faster way. I know this work is not easy, so I should try more and spend more time. thank you anyway for your helpful response :)
    – Mojtaba Ahmadi
    Sep 11 at 6:03










Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f468168%2fmapping-linux-dev-fb0-to-ddr-for-displaying%23new-answer', 'question_page');

);

Post as a guest






























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
2
down vote



accepted










The driver is a linux kernel module.



Download the source of the linux kernel, have a look at the code of the existing framebuffer drivers in drivers/video/fbdev (github here) and the documentation in Documentation/fb (github). Google for tutorials how to write kernel modules, practice with a simple module first.



Just mapping memory won't be enough, you'll have to implement a few ioctls.



Writing kernel drivers is not easy. If you have to ask this kind of questions (and you asked a lot in the past few days), you probably won't be able to do it.



X is a server for the X protocol. It can use hardware via the DRM kernel modules, and it can also use hardware via framebuffer drivers (with the fbdev X driver). Details about that are easy to find online, google. /dev/fb0 is a framebuffer device, so you don't need to concern yourself with X or DRM.






share|improve this answer




















  • thank you. I asked because answers were confusing and in different forums, different answers were given. and I was looking for simpler and faster way. I know this work is not easy, so I should try more and spend more time. thank you anyway for your helpful response :)
    – Mojtaba Ahmadi
    Sep 11 at 6:03














up vote
2
down vote



accepted










The driver is a linux kernel module.



Download the source of the linux kernel, have a look at the code of the existing framebuffer drivers in drivers/video/fbdev (github here) and the documentation in Documentation/fb (github). Google for tutorials how to write kernel modules, practice with a simple module first.



Just mapping memory won't be enough, you'll have to implement a few ioctls.



Writing kernel drivers is not easy. If you have to ask this kind of questions (and you asked a lot in the past few days), you probably won't be able to do it.



X is a server for the X protocol. It can use hardware via the DRM kernel modules, and it can also use hardware via framebuffer drivers (with the fbdev X driver). Details about that are easy to find online, google. /dev/fb0 is a framebuffer device, so you don't need to concern yourself with X or DRM.






share|improve this answer




















  • thank you. I asked because answers were confusing and in different forums, different answers were given. and I was looking for simpler and faster way. I know this work is not easy, so I should try more and spend more time. thank you anyway for your helpful response :)
    – Mojtaba Ahmadi
    Sep 11 at 6:03












up vote
2
down vote



accepted







up vote
2
down vote



accepted






The driver is a linux kernel module.



Download the source of the linux kernel, have a look at the code of the existing framebuffer drivers in drivers/video/fbdev (github here) and the documentation in Documentation/fb (github). Google for tutorials how to write kernel modules, practice with a simple module first.



Just mapping memory won't be enough, you'll have to implement a few ioctls.



Writing kernel drivers is not easy. If you have to ask this kind of questions (and you asked a lot in the past few days), you probably won't be able to do it.



X is a server for the X protocol. It can use hardware via the DRM kernel modules, and it can also use hardware via framebuffer drivers (with the fbdev X driver). Details about that are easy to find online, google. /dev/fb0 is a framebuffer device, so you don't need to concern yourself with X or DRM.






share|improve this answer












The driver is a linux kernel module.



Download the source of the linux kernel, have a look at the code of the existing framebuffer drivers in drivers/video/fbdev (github here) and the documentation in Documentation/fb (github). Google for tutorials how to write kernel modules, practice with a simple module first.



Just mapping memory won't be enough, you'll have to implement a few ioctls.



Writing kernel drivers is not easy. If you have to ask this kind of questions (and you asked a lot in the past few days), you probably won't be able to do it.



X is a server for the X protocol. It can use hardware via the DRM kernel modules, and it can also use hardware via framebuffer drivers (with the fbdev X driver). Details about that are easy to find online, google. /dev/fb0 is a framebuffer device, so you don't need to concern yourself with X or DRM.







share|improve this answer












share|improve this answer



share|improve this answer










answered Sep 11 at 5:53









dirkt

14.9k2932




14.9k2932











  • thank you. I asked because answers were confusing and in different forums, different answers were given. and I was looking for simpler and faster way. I know this work is not easy, so I should try more and spend more time. thank you anyway for your helpful response :)
    – Mojtaba Ahmadi
    Sep 11 at 6:03
















  • thank you. I asked because answers were confusing and in different forums, different answers were given. and I was looking for simpler and faster way. I know this work is not easy, so I should try more and spend more time. thank you anyway for your helpful response :)
    – Mojtaba Ahmadi
    Sep 11 at 6:03















thank you. I asked because answers were confusing and in different forums, different answers were given. and I was looking for simpler and faster way. I know this work is not easy, so I should try more and spend more time. thank you anyway for your helpful response :)
– Mojtaba Ahmadi
Sep 11 at 6:03




thank you. I asked because answers were confusing and in different forums, different answers were given. and I was looking for simpler and faster way. I know this work is not easy, so I should try more and spend more time. thank you anyway for your helpful response :)
– Mojtaba Ahmadi
Sep 11 at 6:03

















 

draft saved


draft discarded















































 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f468168%2fmapping-linux-dev-fb0-to-ddr-for-displaying%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

How to check contact read email or not when send email to Individual?

Bahrain

Postfix configuration issue with fips on centos 7; mailgun relay