<feed xmlns="http://www.w3.org/2005/Atom"> <id>https://www.zfl9.com/</id><title>zfl9's blog</title><subtitle>zfl9 的个人博客，用来记录日常学习过程，分享一些技术知识。</subtitle> <updated>2023-12-11T16:30:48+08:00</updated> <author> <name>zfl9</name> <uri>https://www.zfl9.com/</uri> </author><link rel="self" type="application/atom+xml" href="https://www.zfl9.com/feed.xml"/><link rel="alternate" type="text/html" hreflang="zh-CN" href="https://www.zfl9.com/"/> <generator uri="https://jekyllrb.com/" version="4.3.2">Jekyll</generator> <rights> © 2023 zfl9 </rights> <icon>/assets/img/favicons/favicon.ico</icon> <logo>/assets/img/favicons/favicon-96x96.png</logo> <entry><title>Zig MIPS 软浮点问题</title><link href="https://www.zfl9.com/zig-mips.html" rel="alternate" type="text/html" title="Zig MIPS 软浮点问题" /><published>2023-12-11T11:55:00+08:00</published> <updated>2023-12-11T11:55:00+08:00</updated> <id>https://www.zfl9.com/zig-mips.html</id> <content src="https://www.zfl9.com/zig-mips.html" /> <author> <name>zfl9</name> </author> <category term="zig" /> <summary> 问题描述 在开发 ChinaDNS-NG 2.0 的过程中，遇到一个 MIPS 软浮点目标的链接器错误，zig 版本是 0.10.1。 $ zig build clean-all &amp;amp;&amp;amp; zig build -Dtarget=mips-linux-musl -Dcpu=mips32+soft_float --verbose ... error: ld.lld: /root/chinadns-ng/zig-cache/o/8a51af63d061459702b0b7df54c14aa6/crti.o: floating point ABI '-mdouble-float' is incompatible with target floating point ABI '-msoft-float' error: ld.lld: /root/chinadns-ng/zig-... </summary> </entry> <entry><title>WLAN 笔记</title><link href="https://www.zfl9.com/wlan.html" rel="alternate" type="text/html" title="WLAN 笔记" /><published>2018-11-26T08:00:00+08:00</published> <updated>2018-11-26T08:00:00+08:00</updated> <id>https://www.zfl9.com/wlan.html</id> <content src="https://www.zfl9.com/wlan.html" /> <author> <name>zfl9</name> </author> <category term="linux" /> <summary> 本文主要记录 Linux 与无线网络相关的一些知识和操作笔记，包括：如何编译无线网卡的驱动、如何利用 dkms 在内核更新时自动编译驱动模块、以及 hostapd、wpa_supplicant、iw 等实用工具的用法。 内核模块 在 Linux 中，驱动一般都是通过内核模块的形式提供。内核模块分为 内置模块、可加载模块：内置模块是静态编译进内核的，无需通过 modprobe、insmod、rmmod 来加载、卸载，核心模块一般会内置到内核；而大部分驱动，都是可加载模块，即 *.ko kernel object 内核对象文件。 kernel object 和 object 都是对象文件，但是 kernel object 不能被链接或者直接运行，需要使用 insmod 或 modprobe 来加载它，让它成为内核的一部分，扩展内核的功能。不需要时，可以使用 rmmod 或 modp... </summary> </entry> <entry><title>C语言 进程间通信 管道</title><link href="https://www.zfl9.com/c-ipc-pipe.html" rel="alternate" type="text/html" title="C语言 进程间通信 管道" /><published>2018-05-13T14:00:00+08:00</published> <updated>2018-05-13T14:00:00+08:00</updated> <id>https://www.zfl9.com/c-ipc-pipe.html</id> <content src="https://www.zfl9.com/c-ipc-pipe.html" /> <author> <name>zfl9</name> </author> <category term="c" /> <summary> 匿名管道pipe shell中的管道 如果你使用过Linux的命令，那么对于管道这个名词你一定不会感觉到陌生，因为我们通常通过符号|来使用管道； 但是管道的真正定义是什么呢？ 管道是一个进程连接数据流到另一个进程的通道，它通常是用作把一个进程的输出通过管道连接到另一个进程的输入； 举个例子，在shell中输入命令：ls -l | grep string 我们知道ls命令（其实也是一个进程）会把当前目录中的文件都列出来，但是它不会直接输出，而是把本来要输出到屏幕上的数据通过管道输出到grep这个进程中，作为grep这个进程的输入，然后这个进程对输入的信息进行筛选，把存在string的信息的字符串（以行为单位）打印在屏幕上； pipe创建管道 int pipe(filedes[2]);：创建一个匿名管道 头文件：unistd.h filedes[2]：输出参数... </summary> </entry> <entry><title>C语言 多进程编程</title><link href="https://www.zfl9.com/c-multi-proc.html" rel="alternate" type="text/html" title="C语言 多进程编程" /><published>2018-05-11T11:08:19+08:00</published> <updated>2018-05-11T11:08:19+08:00</updated> <id>https://www.zfl9.com/c-multi-proc.html</id> <content src="https://www.zfl9.com/c-multi-proc.html" /> <author> <name>zfl9</name> </author> <category term="c" /> <summary> 进程、线程 进程是资源分配的最小单位，线程是CPU调度的最小单位 进程(Process) 进程(Process)是计算机中的程序关于某数据集合上的一次运行活动，是系统进行资源分配和调度的基本单位，是操作系统结构的基础； 在早期面向进程设计的计算机结构中，进程是程序的基本执行实体；在当代面向线程设计的计算机结构中，进程是线程的容器； 程序是指令、数据及其组织形式的描述，进程是程序的实体； 线程(Thread) 线程(Thread)，有时被称为轻量级进程(Lightweight Process，LWP)，是程序执行流的最小单元；一个标准的线程由线程ID，当前指令指针(PC)，寄存器集合和堆栈组成； 另外，线程是进程中的一个实体，是被系统独立调度和分派的基本单位，线程自己不拥有系统资源，只拥有一点儿在运行中必不可少的资源，但它可与同属一个进程的其它线程共享进程所拥有的... </summary> </entry> <entry><title>C语言 socket编程(四)</title><link href="https://www.zfl9.com/c-socket-io-model.html" rel="alternate" type="text/html" title="C语言 socket编程(四)" /><published>2018-05-10T11:21:00+08:00</published> <updated>2018-05-10T11:21:00+08:00</updated> <id>https://www.zfl9.com/c-socket-io-model.html</id> <content src="https://www.zfl9.com/c-socket-io-model.html" /> <author> <name>zfl9</name> </author> <category term="c" /> <summary> IO模型 网络IO的本质是socket的操作，我们以recv为例： 每次调用recv，数据会先拷贝到操作系统内核的缓冲区中，然后才会从操作系统内核的缓冲区拷贝到应用程序的地址空间； 所以说，当一个recv操作发生时，它会经历两个阶段： 第一阶段：等待数据准备 第二阶段：将数据从内核拷贝到进程中 对于socket流而言： 第一阶段：通常涉及等待网络上的数据分组到达，然后被复制到内核的某个缓冲区 第二阶段：把数据从内核缓冲区复制到应用进程的缓冲区 网络IO模型 同步IO(synchronous IO) 阻塞IO(bloking IO) 非阻塞IO(non-blocking IO) 多路复用IO(multiplexing IO) 信号驱动式IO(signal-driven IO) ... </summary> </entry> </feed>
