Find Jobs
Hire Freelancers

Teach my daughter (5th year CS student) to build a Linux system character driver(repost)

$100-500 USD

Đã hoàn thành
Đã đăng vào hơn 17 năm trước

$100-500 USD

Thanh toán khi bàn giao
My daughter is a 5th year computer science student and is about to graduate. She is having an issue with understanding Linux system programming as it pertains to character drivers. I am looking for someone to get her up to speed so that she can complete her assignment. I am not neccesarily looking for someone to give her the answer to her assignment - she needs to know the topic. This needs to be tackled ASAP as her assignment is due soon. Please let me know how much time this will take you and how much money you request for this task. ## Deliverables (I am sorry to have to keep re-posting this - trying to get RAC satisfied with the deliverables) The data below can also be viewed here in the actual project site (section number 2): [login to view URL]~cs153a/projects/[login to view URL] While I don't really want you to build the required project below (just tutor my daughter through the project via email or phone) - the required end product that is built between you and my daughter should follow the specifications that are spelled out below. # Character device driver * Character drivers are common and useful. Here is an overview of character drivers in Linux 2.6. You will be writing a similar driver to the SCULL driver presented in this chapter. Please note, that the file_operations data structure described in the document is not what is currently available to us in linux/fs.h. Our file_operations data structure is defined here. * Your driver will manipulate a piece of memory as if it were a device. The goal of this part of the project is to get you comfortable writing character drivers and to help familiarize yourself with the Linux 2.6 interface to do so. You can start with this file, rename the methods as you wish, but be sure to update the file_operations structure if you do so. Build the driver using this Makefile (replace MNAME (if needed) and KDIR). This module compiles and loads in UML. Check that this works before proceeding. * Once you load the module with insmod, use dmesg: UML# dmesg|tail, to see the system messages. You should see something like init cs153a major#: 254 The major number may be different. Use this number to make a node through which users can access your device: UML# mknod /dev/cs153a c 254 0 Look up what this command does to make sure that you understand what is going on above. E.g. what does the 0 mean? Now you can access you char driver. Char drivers are accessed on a per-process basis -- different from block devices that we can mount for all to use. A sample file is here that accesses the device. Notice that the functions used are the same ones that we use to manipulate files. This universal file-based interface is a key to the success of UNIX in general and Linux in particular. Code exercise 3 Extend the driver and the test program to do something interesting. Have the driver access memory instead of a real device. Your driver should operate as a loop-back network interface. Data written (string of chars for simplicity) should be queued in memory until a read operation occurs at which strings are fetched from the queue to the user. Note that your queue may overflow, in which case your driver should log an error with the kernel. A device write/read should insert/remove one string into/from the queue. Use your ioctl call to provide users a way to debug your driver. Use different ioctl commands to report different status information about the various calls. In your [login to view URL], state in details what you did for this extension. Your test.c should test your routines, so if you add any functions, extend the test.c program to make use of them. ## Platform This project requires Linux system programming knowledge in a current version of Linux. That I am aware of, the exact OS should not really matter for this task.
Mã dự án: 3942981

Về dự án

3 đề xuất
Dự án từ xa
Hoạt động 17 năm trước

Bạn muốn kiếm tiền?

Lợi ích khi chào giá trên Freelancer

Thiết lập ngân sách và thời gian
Nhận thanh toán cho công việc
Phác thảo đề xuất của bạn
Miễn phí đăng ký và cháo giá cho công việc
Đã trao cho:
Avatar người dùng
See private message.
$85 USD trong 6 ngày
4,8 (53 nhận xét)
4,7
4,7
3 freelancer chào giá trung bình $184 USD cho công việc này
Avatar người dùng
See private message.
$255 USD trong 6 ngày
5,0 (10 nhận xét)
4,5
4,5
Avatar người dùng
See private message.
$212,50 USD trong 6 ngày
0,0 (0 nhận xét)
0,0
0,0

Về khách hàng

Cờ của UNITED STATES
Lancaster, United States
5,0
1
Thành viên từ thg 5 3, 2006

Xác thực khách hàng

Cảm ơn bạn! Chúng tôi đã gửi email chứa đường link để bạn lấy tín dụng miễn phí.
Đã xảy ra lỗi trong khi gửi email của bạn. Hãy thử lại.
Người Dùng Đã Đăng Ký Tổng Số Việc Đã Đăng
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Đang tải xem trước
Đã cấp quyền truy cập vị trí.
Phiên đăng nhập của bạn đã hết hạn và bạn đã bị đăng xuất. Hãy đăng nhập lại.