留言板

路过的蜗牛们,在这里留个脚印吧~

蜗窝欢迎各种言论,谈天说地、技术交流、问题求救、跳槽招聘、牢骚抱怨……哈哈。

评论:

helloworld
2017-01-20 13:36
</div></span>helloworld><script>ce测试
helloworld
2017-01-20 13:35
</div>helloworld><script>ce测试
WL
2017-01-03 23:35
刚路过,看了一些文章,感觉到博主的情怀和坚持,确实难能可贵,本人也是在linux上摸爬滚打8年的工程师,目前正在从事linux驱动工作,很希望能够参与到一个为技术和产品奋斗的组织,望有机会可以拜见下!
wowo
2017-01-04 14:02
@WL:多谢关注及支持~~有机会的话大家可以聚聚,聊聊天,吹吹牛,呵呵。
madang
2016-12-23 13:45
问个中断的问题,当代码运行在cpu A上时候,如何查看cpu B
的中断是否打开?

我知道查看本核的是irq_disabled()
wowo
2017-01-04 09:18
@madang:kernel应该没有这样的接口。因为A为什么要关心B的中断使能状态呢?和它完全没有关系啊。
lolo84
2016-12-14 16:12
有没有浅显易懂的makefile 的书写文档,貌似初学者比较懵
wowo
2016-12-14 16:42
@lolo84:说实话,关于Makefile,我一直有类似的困惑,一直……
个人意见,不要试图去看什么一劳永逸的书(太琐碎,记不着),比较有效的方法是实践:
1. 手头上有很多开源软件的Makefile,用尽一些方法把它们看懂(google等)。
2. 动手写,例如我们的x project,用Makefile将各个软件包串起来。
用的多了,自然熟能生巧。不过到最后很有可能还是记不全,不过又有什么关系呢?用到的时候去查一下就行了。
yoyoriten
2016-12-14 11:27
请问下有人了解过linux下的上行组包吗?有人了解这个原理吗?现在linux内核代码中具体是怎么实现的呢?谢谢!
wowo
2016-12-14 16:01
@yoyoriten:上行组包是个什么概念?兄台的问题有点过于简洁了,呵呵
Z-team
2016-10-10 21:13
想深入了解下linux kernel中vfs这一subsystem,但是自己读相关的源码很是费力,希望以后能有这一知识的全面介绍,很是期待。
linuxer
2016-10-10 21:56
@Z-team:当前估计很难涉及这一块,毕竟人的精力是有限的,时间也是有限的......希望未来有机会吧,哈哈
驴肉火烧
2016-10-13 09:20
@linuxer:@linuxer,我对文件系统这块有一些研究,可以给你们投稿么
linuxer
2016-10-13 12:12
@驴肉火烧:当然可以啊,非常的欢迎,我们需要为你创建一个blog的帐号,你打算其一个什么样的名字呢?驴肉火烧吗?
驴肉火烧
2016-10-14 12:30
@linuxer:好啊,就这个名字吧,驴肉火烧很好吃哦,哈哈
wowo
2016-10-14 13:17
@驴肉火烧:已添加,用户名:驴肉火烧 ,密码:123321
尽快登录改密码哦,最好把邮箱信息也补充一下~~
多谢分享哦:-)
CHENYAN
2016-09-27 16:52
最近一直在研究ARM64 Linux的系统调用的HOOK方法. 记得以前X86平台下可以通过IDT寄存器获取系统调用表的基地址. 我看了ARM64的内核代码, 貌似没有类似的寄存器. 想问一下ARM64有办法获取系统调用表的基地址吗? 我对ARM64架构不是很熟悉, 能给点指导意见吗? 感谢!!!  @wowo
hongxiaoh
2016-08-11 14:16
cec = atomic_add_return(MAX_IN_PROGRESS, &combined_event_count);
wakeup events in progress减1,registered wakeup events加1
请问这个具体是怎么实现加减的?
wowo
2016-08-11 15:42
@hongxiaoh:假设combined_event_count是32bit
wakeup events in progress和registered wakeup events各占16bit,即:wakeup events in progress | registered wakeup events.
注:上面有一个隐含的规则:registered wakeup events > wakeup events in progress(很重要,不然会有问题)
而MAX_IN_PROGRESS等于((1 << 16) - 1),即0xffff
那么combined_event_count + MAX_IN_PROGRESS = ?
假设combined_event_count=0x0 0001,则为0x1 0000
假设combined_event_count=0x5 0009,则为0x6 0008
实际上就利用了简单的进位操作~~~
hongxiaoh
2016-08-30 13:46
@wowo:#define pr_fmt(fmt)    "%s: " fmt, __func__

请问知道这句话的语法吗??
在linux lcd驱动看到的这句话。
wowo
2016-08-30 18:19
@hongxiaoh:pr_fmt是为了在printk输出的log之前,加一些关键字,一般是标识自己的模块的(一次都是放在自己模块C代码的开始处),你可以参考include/linux/printk.h中的用法,如:
#define pr_info(fmt, ...) \                                                    
        printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
hongxiaoh
2016-09-06 15:35
@wowo:您好,有没有什么方法设置   关机充电  可以进入adb 模式??
为了获取关机充电的一些log。
wowo
2016-09-06 17:23
@hongxiaoh:不知道你使用哪个版本的Android?
以我了解的Android5.0为例,关机充电和正常工作,从本质上来讲,是没有什么区别的,只是运行了不同的Application(例如healthd),此时Adb的service和protocol,很有可能是存在的(依赖Android的配置),如果你需要查看日志,估计需要把相应的环境(如logcat等)启动:
例如下面是我的机器在关机充电的时候的打印(没有shell、没有logcat等等)
adb logcat
- exec '/system/bin/sh' failed: No such file or directory (2) -

具体怎么做,和Android的版本、编译、配置策略有关,具体我也不是很熟悉~~
likai
2016-08-05 11:16
qcom,power-on@800 {
            compatible = "qcom,qpnp-power-on";
            reg = <0x800 0x100>;
            interrupts = <0x0 0x8 0x0>,
                <0x0 0x8 0x1>,
                <0x0 0x8 0x4>,
                <0x0 0x8 0x5>;//这个代表的什么含义呢?
            interrupt-names = "kpdpwr", "resin",
                "resin-bark", "kpdpwr-resin-bark";
            qcom,pon-dbc-delay = <15625>;
            qcom,system-reset;

            qcom,pon_1 {
                qcom,pon-type = <0>;
                qcom,pull-up = <1>;
                linux,code = <116>;
            };

            qcom,pon_2 {
                qcom,pon-type = <1>;
                qcom,pull-up = <1>;
                linux,code = <114>;
            };
            qcom,pon_3 {
                qcom,pon-type = <3>;
                qcom,support-reset = <1>;
                qcom,s1-timer = <6720>;
                qcom,s2-timer = <2000>;
                qcom,s2-type = <7>;
                qcom,pull-up = <1>;
                qcom,use-bark;
            };
        };
我有一个疑问,可否帮忙解答解答。interrupts = <0x0 0x8 0x0> 代表的都是什么含义呢,非常感谢。
wowo
2016-08-05 12:27
@likai:你可以参考对应的device tree bindings文档,例如(这里不一定是你的真实场景。另外如果找不到文档,可以直接看代码,我们不知道你的平台,具体的含义也无法确定):
Documentation/devicetree/bindings/interrupt-controller/arm,gic.txt

- #interrupt-cells : Specifies the number of cells needed to encode an
  interrupt source.  The type shall be a <u32> and the value shall be 3.

  The 1st cell is the interrupt type; 0 for SPI interrupts, 1 for PPI
  interrupts.

  The 2nd cell contains the interrupt number for the interrupt type.
  SPI interrupts are in the range [0-987].  PPI interrupts are in the
  range [0-15].

  The 3rd cell is the flags, encoded as follows:
        bits[3:0] trigger type and level flags.
                1 = low-to-high edge triggered
                2 = high-to-low edge triggered (invalid for SPIs)
                4 = active high level-sensitive
                8 = active low level-sensitive (invalid for SPIs).
        bits[15:8] PPI interrupt cpu mask.  Each bit corresponds to each of
        the 8 possible cpus attached to the GIC.  A bit set to '1' indicated
        the interrupt is wired to that CPU.  Only valid for PPI interrupts.
        Also note that the configurability of PPI interrupts is IMPLEMENTATION
        DEFINED and as such not guaranteed to be present (most SoC available
        in 2014 seem to ignore the setting of this flag and use the hardware
        default value).
likai
2016-08-05 15:08
@wowo:非常感谢,wowo的回复效率这么高。

发表评论:

Copyright @ 2013-2015 蜗窝科技 All rights reserved. Powered by emlog