当前位置:首页>Linux>Linux ALSA驱动之 controls

Linux ALSA驱动之 controls

  • 2026-02-21 22:28:45
Linux ALSA驱动之 controls

Linux ALSA驱动之 controls

ALSA 的控件机制是 ALSA 驱动框架中一个核心且强大的部分,它为用户空间程序(如混音器、音频服务器 PulseAudio/PipeWire、媒体播放器等)提供了一个统一、标准的接口,用于查询和操作声卡上各种复杂的音频参数。

1. tinymix

tinymix 是一个用于控制 Android 系统音频混音器(Audio Mixer)的命令行工具

1.1 使用范例

"DAC VOLUME" 是 ALSA 框架中 用于控制 DAC 声音输出音量的控件。

查询当前音量:

tinymix "DAC VOLUME"        

返回:

DAC VOLUME: 191 (dsrange 0->255)

设置音量:

tinymix "DAC VOLUME" 225

查询是否设置成功:

tinymix "DAC VOLUME"

返回:

DAC VOLUME: 225 (dsrange 0->255)

1.2 与内核交互的系统调用序列

# 用户命令tinymix "DAC VOLUME" 225# 实际系统调用序列1. open("/dev/snd/controlC0", O_RDWR)        # 打开控制设备2. ioctl(fd, SNDRV_CTL_IOCTL_ELEM_INFO, ...) # 查询控件信息3. ioctl(fd, SNDRV_CTL_IOCTL_ELEM_READ, ...) # 读取当前值4. ioctl(fd, SNDRV_CTL_IOCTL_ELEM_WRITE, ...)# 写入新值5. close(fd)

由此引出问题: 声卡控制设备节点 "/dev/snd/controlC0" 与控件 "DAC VOLUME" 在内核中是怎样建立联系的?

2. Kernel Space

先上个 "DAC VOLUME" 控件与声卡实例 snd_soc_card_holi_msm 之间的关联图:

2.1 Codec Driver

2.1.1 注册 snd_soc_component

es8311_i2c_probe()中:

static conststruct snd_kcontrol_new es8311_snd_controls[] = {    SOC_SINGLE_TLV("DAC VOLUME", ES8311_DAC_REG32,            0, 255, 0, vdac_tlv),}staticstruct snd_soc_component_driver soc_component_dev_es8311 = {    .controls = es8311_snd_controls,    .num_controls = ARRAY_SIZE(es8311_snd_controls),};static int es8311_i2c_probe(struct i2c_client *i2c_client,                    const struct i2c_device_id *id){    ret =  snd_soc_register_component(&i2c_client->dev,            &soc_component_dev_es8311,            &es8311_dai,            1);}

snd_soc_register_component()里会创建一个snd_soc_component实例,我们姑且命名为es8311_component:

//sound/soc/soc-core.cint snd_soc_register_component(struct device *dev,            const struct snd_soc_component_driver *component_driver,            struct snd_soc_dai_driver *dai_drv,            int num_dai){struct snd_soc_component *component;    /* 创建 snd_soc_component 实例 */    component = devm_kzalloc(dev, sizeof(*component), GFP_KERNEL);    if (!component)        return -ENOMEM;    return snd_soc_add_component(dev, component, component_driver,                     dai_drv, num_dai);}

接着走

snd_soc_add_component()├── snd_soc_component_initialize()└── snd_soc_component_add()
  • • 在 snd_soc_component_initialize() 里将关系图中的es8311_devsoc_component_dev_es8311赋值给es8311_component
  • • 在snd_soc_component_add()里将es8311_component链到全局变量component_list

至此,代表es8311snd_soc_component已注册完成,通过遍历全局变量component_list可找到es8311_component"DAC VOLUME"控件和es8311_component的关系如下:

es8311_component : snd_soc_component└── soc_component_dev_es8311 : snd_soc_component_driver    └── es8311_snd_controls[] : snd_kcontrol_new        ├── "MIC PGA GAIN"        ├── "DAC VOLUME"        ├── ....        └── "MCLK SOURCE"

2.2 Card Driver

2.2.1 注册 snd_soc_card

msm_asoc_machine_probe() {struct snd_soc_card card = populate_snd_card_dailinks(&pdev->dev)    msm_populate_dai_link_component_of_node(card)    devm_snd_soc_register_card(&pdev->dev, card)}

msm_asoc_machine_probe():

  • • 往snd_soc_card实例snd_soc_card_holi_msm填充dai_link,见populate_snd_card_dailinks()
  • • 往dai_link填充of_node,见msm_populate_dai_link_component_of_node()
  • • 注册snd_soc_card_holi_msm

2.2.2 绑定 snd_soc_dai_link

devm_snd_soc_register_card()└── snd_soc_register_card()    └── snd_soc_bind_card()        └── snd_soc_instantiate_card()            ├── soc_init_dai_link()            |   └── soc_find_component()            |       └── snd_soc_is_matching_component()            └── soc_bind_dai_link()

soc_init_dai_link()里会判断snd_soc_dai_link.codecsnd_soc_dai_link.platform对应的snd_soc_component是否已经注册到全局变量component_list里:

static int soc_init_dai_link(struct snd_soc_card *card,                 struct snd_soc_dai_link *link){    for_each_link_codecs(link, i, codec) {        /*         * Defer card registration if codec component is not added to         * component list.         */        if (!soc_find_component(codec))            return -EPROBE_DEFER;    }}static struct snd_soc_component *soc_find_component(    const struct snd_soc_dai_link_component *dlc){    for_each_component(component)        if (snd_soc_is_matching_component(dlc, component))            return component;    return NULL;}

snd_soc_is_matching_component()的匹配方法中使用的of_nodemsm_populate_dai_link_component_of_node()中填充的of_node是相对应的:

static int snd_soc_is_matching_component(    const struct snd_soc_dai_link_component *dlc,    struct snd_soc_component *component){struct device_node *component_of_node;    if (!dlc)        return 0;    component_of_node = soc_component_to_node(component);    if (dlc->of_node && component_of_node != dlc->of_node)        return 0;    if (dlc->name && strcmp(component->name, dlc->name))        return 0;    return 1;}

snd_soc_is_matching_component()示意图:

soc_bind_dai_link()||   /* 创建 snd_soc_pcm_runtime */├── soc_new_pcm_runtime()||   /* 查找匹配的 snd_soc_dai 绑定到 snd_soc_pcm_runtime */├── snd_soc_find_dai()||   /* 将上面 snd_soc_dai 对应的 snd_soc_component|    绑定到 snd_soc_pcm_runtime*/├── snd_soc_rtdcom_add()||   /* 将 snd_soc_pcm_runtime 绑定到 snd_soc_card */└── soc_add_pcm_runtime()

如何查找匹配的 snd_soc_dai:snd_soc_find_dai(const struct snd_soc_dai_link_component *dlc)

  • • 遍历全局变量component_list中的snd_soc_component实例
  • • 从snd_soc_component.dai_list中遍历出snd_soc_dai实例
  • • snd_soc_dai.namesnd_soc_dai.driver.namesnd_soc_dai_link_component.dai_name相等的话,返回相应的snd_soc_dai

snd_soc_find_dai()函数示意图:

snd_soc_rtdcom_add()snd_soc_dai.component指向的snd_soc_component加到snd_soc_pcm_runtime.component_list

2.2.3 创建snd_cardcontrolC0文件

snd_soc_instantiate_card()|   /* 在 snd_soc_card 绑定 snd_soc_dai_link 完成后, 创建 snd_card */└── snd_card_new()     └── snd_ctl_create() //创建 /dev/snd/controlC0 文件

struct snd_card用来关联controlssnd_soc_card:

snd_soc_card└── snd_card    └── controls[0..N] : snd_kcontrol     

/dev/snd/controlC0 是 ALSA 控制接口设备文件,主要用于音频系统的控制和状态管理:

a. 音频设备控制
  • • 音量控制:调节主音量、PCM音量、各通道音量
  • • 通道开关:静音/取消静音
  • • 音效控制:均衡器、3D音效、重低音等
  • • 路由切换:输入输出端口选择
b. 设备信息查询
  • • 获取设备能力(支持的格式、采样率等)
  • • 查询混音器(mixer)元素信息
  • • 枚举可用音频设备
c. 音频路由管理
  • • 控制音频数据流的路径
  • • 管理多个音频源/目的地的连接例如tinymix命令就是通过操作/dev/snd/controlC0 这个文件来控制音频系统的。

2.2.3 soc_probe_link_components()

soc_probe_link_components()用于 probe snd_soc_card 上所有被 snd_soc_dai_link 使用的 snd_soc_component

  • • 将相关联的 N 个snd_soc_component加到snd_soc_card的管理链表里
  • • 将相关联的 N 个snd_kcontrol_new加到snd_soc_card.snd_card的管理链表里
snd_soc_instantiate_card()└── soc_probe_link_components() 
static int soc_probe_link_components(struct snd_soc_card *card){struct snd_soc_component *component;struct snd_soc_pcm_runtime *rtd;struct snd_soc_rtdcom_list *rtdcom;    int ret, order;    dev_err(card->dev, "%s: %s\n", __func__, card->name);    for_each_comp_order(order) {        for_each_card_rtds(card, rtd) {            for_each_rtdcom(rtd, rtdcom) {                component = rtdcom->component;                if (component->driver->probe_order != order)                    continue;                ret = soc_probe_component(card, component);                if (ret < 0)                    return ret;            }        }    }    return 0;}

soc_probe_link_components(struct snd_soc_card *card)

  • • 从snd_soc_card中遍历出snd_soc_pcm_runtime
  • • 从snd_soc_pcm_runtime中遍历出snd_soc_component
  • • 调用soc_probe_component(card, component)
soc_probe_link_components()└── soc_probe_component(snd_soc_card *card, nd_soc_component *component)    |    ├── component->card = card;    |        ├── snd_soc_add_component_controls() 添加控制项    |    |    |    |   /* 将控制项添加到 snd_card 的 controls 链表中 */    |    └── snd_soc_add_controls()    |        |   /* 将component添加到card的component_dev_list中 */    └── list_add(&component->card_list, &card->component_dev_list);

snd_soc_add_controls()snd_kcontrol_new类型的controls转换为snd_kcontrol添加到snd_card.controls里。

3. tinymix -> CODEC芯片 数据流

读取control的值

int mixer_ctl_get_value(struct mixer_ctl *ctl, unsigned int id){struct snd_ctl_elem_value ev;    memset(&ev, 0, sizeof(ev));    ev.id.numid = ctl->info->id.numid;    ret = ioctl(ctl->mixer->fd, SNDRV_CTL_IOCTL_ELEM_READ, &ev);}

kernelSNDRV_CTL_IOCTL_ELEM_READ命令的实现:

static long snd_ctl_ioctl(struct file *file, unsigned int cmd, unsigned long arg){    switch (cmd) {    case SNDRV_CTL_IOCTL_ELEM_READ:        return snd_ctl_elem_read_user(card, argp);    }}static int snd_ctl_elem_read_user(struct snd_card *card,                  struct snd_ctl_elem_value __user *_control){struct snd_ctl_elem_value *control;    control = memdup_user(_control, sizeof(*control));    result = snd_ctl_elem_read(card, control);    if (copy_to_user(_control, control, sizeof(*control)))        result = -EFAULT;}static int snd_ctl_elem_read(struct snd_card *card,                 struct snd_ctl_elem_value *control){struct snd_kcontrol *kctl;struct snd_kcontrol_volatile *vd;    unsigned int index_offset;    kctl = snd_ctl_find_id(card, &control->id);    if (kctl == NULL)        return -ENOENT;    index_offset = snd_ctl_get_ioff(kctl, &control->id);    vd = &kctl->vd[index_offset];    if (!(vd->access & SNDRV_CTL_ELEM_ACCESS_READ) || kctl->get == NULL)        return -EPERM;    snd_ctl_build_ioff(&control->id, kctl, index_offset);    return kctl->get(kctl, control);}

kctl->get指向哪里呢,这里插个"DAC VOLUME"的定义:

static conststruct snd_kcontrol_new es8311_snd_controls[] = {    SOC_SINGLE_TLV("DAC VOLUME", ES8311_DAC_REG32,            0, 255, 0, vdac_tlv),}#define SOC_DOUBLE_VALUE(xreg, shift_left, shift_right, xmax, xinvert, xautodisable) \    ((unsigned long)&(struct soc_mixer_control) \    {.reg = xreg, .rreg = xreg, .shift = shift_left, \    .rshift = shift_right, .max = xmax, .platform_max = xmax, \    .invert = xinvert, .autodisable = xautodisable})#define SOC_SINGLE_VALUE(xreg, xshift, xmax, xinvert, xautodisable) \    SOC_DOUBLE_VALUE(xreg, xshift, xshift, xmax, xinvert, xautodisable)#define SOC_SINGLE_TLV(xname, reg, shift, max, invert, tlv_array) \{    .iface = SNDRV_CTL_ELEM_IFACE_MIXER, .name = xname, \    .access = SNDRV_CTL_ELEM_ACCESS_TLV_READ |\         SNDRV_CTL_ELEM_ACCESS_READWRITE,\    .tlv.p = (tlv_array), \    .info = snd_soc_info_volsw, .get = snd_soc_get_volsw,\    .put = snd_soc_put_volsw, \    .private_value = SOC_SINGLE_VALUE(reg, shift, max, invert, 0) }

展开宏后:

{    .iface = SNDRV_CTL_ELEM_IFACE_MIXER,    .name = "DAC VOLUME",    .access = SNDRV_CTL_ELEM_ACCESS_TLV_READ | SNDRV_CTL_ELEM_ACCESS_READWRITE,    .tlv.p = (vadc_tlv),    .info = snd_soc_info_volsw, .get = snd_soc_get_volsw,    .put = snd_soc_put_volsw,    .private_value = ((unsigned long)&(struct soc_mixer_control)          {.reg = ES8311_DAC_REG32, .rreg = ES8311_DAC_REG32, .shift = 0, \    .rshift = 0, .max = 255, .platform_max = 255, \    .invert = 0, .autodisable = 0})}

所以,"DAC VOLUME" 的 kctl->get 指向函数snd_soc_get_volsw():

int snd_soc_get_volsw(struct snd_kcontrol *kcontrol,    struct snd_ctl_elem_value *ucontrol){struct soc_mixer_control *mc =        (struct soc_mixer_control *)kcontrol->private_value;    /* 得到设置"DAC VOLUME"的寄存器 ES8311_DAC_REG32 */    unsigned int reg = mc->reg;    /* 从寄存器 ES8311_DAC_REG32 中读取数据 */    ret = snd_soc_read_signed(component, reg, mask, shift, sign_bit, &val);}static int snd_soc_read_signed(struct snd_soc_component *component,    unsigned int reg, unsigned int mask, unsigned int shift,    unsigned int sign_bit, int *signed_val){    ret = snd_soc_component_read(component, reg, &val);}int snd_soc_component_read(struct snd_soc_component *component,    unsigned int reg, unsigned int *val){    int ret;    if (component->regmap)        ret = regmap_read(component->regmap, reg, val);    else if (component->driver->read) {        *val = component->driver->read(component, reg);        ret = 0;    }    else        ret = -EIO;    return ret;}

所以,tinymix 读取控件值的完整路径:

用户命令: tinymix "DAC VOLUME"         ↓tinymix: mixer_ctl_get_value()         ↓系统调用: ioctl(SNDRV_CTL_IOCTL_ELEM_READ)         ↓内核: snd_ctl_elem_read_user() → 查找控件 → 调用驱动的 get() 回调         ↓驱动: snd_soc_get_volsw() → 读取硬件寄存器         ↓硬件: I2C读取 → 返回寄存器值 → 映射为用户值         ↓tinymix: 显示 "DAC VOLUME: 150"

设置control的值

整体流程跟读取差不多,代码不再赘述,下面是tinymix 设置控件值的完整路径:

用户命令: tinymix "DAC VOLUME" 192         ↓tinymix: mixer_ctl_set_value()         ↓系统调用: ioctl(SNDRV_CTL_IOCTL_ELEM_WRITE)         ↓内核: snd_ctl_elem_write_user() → 查找控件 → 调用驱动的 put() 回调         ↓驱动: snd_soc_put_volsw() → 映射为寄存器值 → I2C写入         ↓硬件: CODEC芯片更新DAC增益寄存器         ↓实时生效: 后续音频数据使用新的增益系数

最新文章

随机文章

基本 文件 流程 错误 SQL 调试
  1. 请求信息 : 2026-03-01 03:10:51 HTTP/2.0 GET : https://f.mffb.com.cn/a/475390.html
  2. 运行时间 : 0.077570s [ 吞吐率:12.89req/s ] 内存消耗:4,777.86kb 文件加载:140
  3. 缓存信息 : 0 reads,0 writes
  4. 会话信息 : SESSION_ID=fbf999ccc5ec196257182722ec07b676
  1. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/public/index.php ( 0.79 KB )
  2. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/autoload.php ( 0.17 KB )
  3. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/composer/autoload_real.php ( 2.49 KB )
  4. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/composer/platform_check.php ( 0.90 KB )
  5. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/composer/ClassLoader.php ( 14.03 KB )
  6. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/composer/autoload_static.php ( 4.90 KB )
  7. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-helper/src/helper.php ( 8.34 KB )
  8. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-validate/src/helper.php ( 2.19 KB )
  9. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/helper.php ( 1.47 KB )
  10. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/stubs/load_stubs.php ( 0.16 KB )
  11. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Exception.php ( 1.69 KB )
  12. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-container/src/Facade.php ( 2.71 KB )
  13. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/symfony/deprecation-contracts/function.php ( 0.99 KB )
  14. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/symfony/polyfill-mbstring/bootstrap.php ( 8.26 KB )
  15. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/symfony/polyfill-mbstring/bootstrap80.php ( 9.78 KB )
  16. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/symfony/var-dumper/Resources/functions/dump.php ( 1.49 KB )
  17. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-dumper/src/helper.php ( 0.18 KB )
  18. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/symfony/var-dumper/VarDumper.php ( 4.30 KB )
  19. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/App.php ( 15.30 KB )
  20. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-container/src/Container.php ( 15.76 KB )
  21. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/psr/container/src/ContainerInterface.php ( 1.02 KB )
  22. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/provider.php ( 0.19 KB )
  23. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Http.php ( 6.04 KB )
  24. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-helper/src/helper/Str.php ( 7.29 KB )
  25. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Env.php ( 4.68 KB )
  26. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/common.php ( 0.03 KB )
  27. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/helper.php ( 18.78 KB )
  28. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Config.php ( 5.54 KB )
  29. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/app.php ( 0.95 KB )
  30. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/cache.php ( 0.78 KB )
  31. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/console.php ( 0.23 KB )
  32. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/cookie.php ( 0.56 KB )
  33. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/database.php ( 2.48 KB )
  34. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/facade/Env.php ( 1.67 KB )
  35. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/filesystem.php ( 0.61 KB )
  36. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/lang.php ( 0.91 KB )
  37. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/log.php ( 1.35 KB )
  38. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/middleware.php ( 0.19 KB )
  39. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/route.php ( 1.89 KB )
  40. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/session.php ( 0.57 KB )
  41. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/trace.php ( 0.34 KB )
  42. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/config/view.php ( 0.82 KB )
  43. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/event.php ( 0.25 KB )
  44. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Event.php ( 7.67 KB )
  45. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/service.php ( 0.13 KB )
  46. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/AppService.php ( 0.26 KB )
  47. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Service.php ( 1.64 KB )
  48. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Lang.php ( 7.35 KB )
  49. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/lang/zh-cn.php ( 13.70 KB )
  50. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/initializer/Error.php ( 3.31 KB )
  51. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/initializer/RegisterService.php ( 1.33 KB )
  52. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/services.php ( 0.14 KB )
  53. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/service/PaginatorService.php ( 1.52 KB )
  54. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/service/ValidateService.php ( 0.99 KB )
  55. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/service/ModelService.php ( 2.04 KB )
  56. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-trace/src/Service.php ( 0.77 KB )
  57. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Middleware.php ( 6.72 KB )
  58. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/initializer/BootService.php ( 0.77 KB )
  59. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/Paginator.php ( 11.86 KB )
  60. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-validate/src/Validate.php ( 63.20 KB )
  61. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/Model.php ( 23.55 KB )
  62. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/model/concern/Attribute.php ( 21.05 KB )
  63. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/model/concern/AutoWriteData.php ( 4.21 KB )
  64. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/model/concern/Conversion.php ( 6.44 KB )
  65. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/model/concern/DbConnect.php ( 5.16 KB )
  66. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/model/concern/ModelEvent.php ( 2.33 KB )
  67. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/model/concern/RelationShip.php ( 28.29 KB )
  68. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-helper/src/contract/Arrayable.php ( 0.09 KB )
  69. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-helper/src/contract/Jsonable.php ( 0.13 KB )
  70. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/model/contract/Modelable.php ( 0.09 KB )
  71. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Db.php ( 2.88 KB )
  72. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/DbManager.php ( 8.52 KB )
  73. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Log.php ( 6.28 KB )
  74. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Manager.php ( 3.92 KB )
  75. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/psr/log/src/LoggerTrait.php ( 2.69 KB )
  76. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/psr/log/src/LoggerInterface.php ( 2.71 KB )
  77. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Cache.php ( 4.92 KB )
  78. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/psr/simple-cache/src/CacheInterface.php ( 4.71 KB )
  79. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-helper/src/helper/Arr.php ( 16.63 KB )
  80. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/cache/driver/File.php ( 7.84 KB )
  81. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/cache/Driver.php ( 9.03 KB )
  82. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/contract/CacheHandlerInterface.php ( 1.99 KB )
  83. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/Request.php ( 0.09 KB )
  84. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Request.php ( 55.78 KB )
  85. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/middleware.php ( 0.25 KB )
  86. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Pipeline.php ( 2.61 KB )
  87. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-trace/src/TraceDebug.php ( 3.40 KB )
  88. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/middleware/SessionInit.php ( 1.94 KB )
  89. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Session.php ( 1.80 KB )
  90. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/session/driver/File.php ( 6.27 KB )
  91. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/contract/SessionHandlerInterface.php ( 0.87 KB )
  92. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/session/Store.php ( 7.12 KB )
  93. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Route.php ( 23.73 KB )
  94. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/route/RuleName.php ( 5.75 KB )
  95. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/route/Domain.php ( 2.53 KB )
  96. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/route/RuleGroup.php ( 22.43 KB )
  97. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/route/Rule.php ( 26.95 KB )
  98. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/route/RuleItem.php ( 9.78 KB )
  99. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/route/app.php ( 1.72 KB )
  100. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/facade/Route.php ( 4.70 KB )
  101. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/route/dispatch/Controller.php ( 4.74 KB )
  102. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/route/Dispatch.php ( 10.44 KB )
  103. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/controller/Index.php ( 4.81 KB )
  104. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/app/BaseController.php ( 2.05 KB )
  105. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/facade/Db.php ( 0.93 KB )
  106. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/connector/Mysql.php ( 5.44 KB )
  107. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/PDOConnection.php ( 52.47 KB )
  108. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/Connection.php ( 8.39 KB )
  109. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/ConnectionInterface.php ( 4.57 KB )
  110. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/builder/Mysql.php ( 16.58 KB )
  111. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/Builder.php ( 24.06 KB )
  112. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/BaseBuilder.php ( 27.50 KB )
  113. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/Query.php ( 15.71 KB )
  114. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/BaseQuery.php ( 45.13 KB )
  115. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/TimeFieldQuery.php ( 7.43 KB )
  116. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/AggregateQuery.php ( 3.26 KB )
  117. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/ModelRelationQuery.php ( 20.07 KB )
  118. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/ParamsBind.php ( 3.66 KB )
  119. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/ResultOperation.php ( 7.01 KB )
  120. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/WhereQuery.php ( 19.37 KB )
  121. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/JoinAndViewQuery.php ( 7.11 KB )
  122. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/TableFieldInfo.php ( 2.63 KB )
  123. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-orm/src/db/concern/Transaction.php ( 2.77 KB )
  124. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/log/driver/File.php ( 5.96 KB )
  125. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/contract/LogHandlerInterface.php ( 0.86 KB )
  126. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/log/Channel.php ( 3.89 KB )
  127. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/event/LogRecord.php ( 1.02 KB )
  128. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-helper/src/Collection.php ( 16.47 KB )
  129. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/facade/View.php ( 1.70 KB )
  130. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/View.php ( 4.39 KB )
  131. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Response.php ( 8.81 KB )
  132. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/response/View.php ( 3.29 KB )
  133. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/Cookie.php ( 6.06 KB )
  134. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-view/src/Think.php ( 8.38 KB )
  135. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/framework/src/think/contract/TemplateHandlerInterface.php ( 1.60 KB )
  136. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-template/src/Template.php ( 46.61 KB )
  137. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-template/src/template/driver/File.php ( 2.41 KB )
  138. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-template/src/template/contract/DriverInterface.php ( 0.86 KB )
  139. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/runtime/temp/067d451b9a0c665040f3f1bdd3293d68.php ( 11.98 KB )
  140. /yingpanguazai/ssd/ssd1/www/f.mffb.com.cn/vendor/topthink/think-trace/src/Html.php ( 4.42 KB )
  1. CONNECT:[ UseTime:0.000532s ] mysql:host=127.0.0.1;port=3306;dbname=f_mffb;charset=utf8mb4
  2. SHOW FULL COLUMNS FROM `fenlei` [ RunTime:0.000602s ]
  3. SELECT * FROM `fenlei` WHERE `fid` = 0 [ RunTime:0.000358s ]
  4. SELECT * FROM `fenlei` WHERE `fid` = 63 [ RunTime:0.000272s ]
  5. SHOW FULL COLUMNS FROM `set` [ RunTime:0.000492s ]
  6. SELECT * FROM `set` [ RunTime:0.000208s ]
  7. SHOW FULL COLUMNS FROM `article` [ RunTime:0.000566s ]
  8. SELECT * FROM `article` WHERE `id` = 475390 LIMIT 1 [ RunTime:0.001601s ]
  9. UPDATE `article` SET `lasttime` = 1772305851 WHERE `id` = 475390 [ RunTime:0.001997s ]
  10. SELECT * FROM `fenlei` WHERE `id` = 67 LIMIT 1 [ RunTime:0.000231s ]
  11. SELECT * FROM `article` WHERE `id` < 475390 ORDER BY `id` DESC LIMIT 1 [ RunTime:0.000392s ]
  12. SELECT * FROM `article` WHERE `id` > 475390 ORDER BY `id` ASC LIMIT 1 [ RunTime:0.000389s ]
  13. SELECT * FROM `article` WHERE `id` < 475390 ORDER BY `id` DESC LIMIT 10 [ RunTime:0.001268s ]
  14. SELECT * FROM `article` WHERE `id` < 475390 ORDER BY `id` DESC LIMIT 10,10 [ RunTime:0.001000s ]
  15. SELECT * FROM `article` WHERE `id` < 475390 ORDER BY `id` DESC LIMIT 20,10 [ RunTime:0.001396s ]
0.079200s