来公司也有一段,一直是让我负责做9054驱动程序的开发。这段时间终于差不多了,趁着还熟悉,就整理下。
既然是9054这种广为流传的芯片,自然有官方的模板代码,再从头开发一套肯定是不划算的。
于是就有了本文描述的基于PLX_SDK的9054驱动程序的开发。
首先是安装PLX_SDK的系统要求:
1. 内核版本不能高于2.7,即不能是3.0版本的内核
2.编译驱动的时候,必须有内核版本对应的内核源代码的支持
如果以上没有问题,那OK,我们继续。
第一步: 下官网下载PLX_SDK,有WINDOWS版的,也有Linux版的,这里使用的版本是PLX_SDK_Linux_v6_50_Final_2011-09-30.zip。
第二步: 解压,打开Documentation\PLX_Linux_Release_Notes.htm,查看具体的安装步骤和要求。
To install the Linux support files, use the following steps:
1. Copy the PLX Linux TAR file to the desired working directory, e.g. the user’s home directory or/usr/linux/src.
拷贝PLX Linux 压缩包至工作目录,例如/usr/linux/src,这里我的工作目录是/usr/src
2. If the PLX file contains a .gz extension, the file must first be unzipped, as follows:
gunzip PlxSdk.tar.gz