非cpu0启动linux,SD卡无法启动Linux的问题及解决

最近在Zynq板上启动linaro桌面系统时,发现一个奇怪的问题,系统在启动到最后,已经打印了如下信息:[drm] Initialized axi_hdmi_drm 1.0.0 20120930 on minor 0,按理说后面就该是登录系统并显示shell提示符了,但后面显示:VFS: Cannot open root device "mmcblk0p2" or unknown-block(179,2): error -30,即打不开SD卡的第二个分区,之前使用这张卡可正常启动的,而且没有做任何改动。于是我们重新制作桌面文件系统,结果问题依旧。很不解?!下面是启动信息:

U-Boot 2013.01 (Jun 04 2013 - 09:22:41)

DRAM:  512 MiB

WARNING: Caches not enabled

MMC:   zynq_sdhci: 0

SF: Detected S25FL256S with page size 64 KiB, total 32 MiB

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   Gem.e000b000

Hit any key to stop autoboot:  0

Copying Linux from SD to RAM...

Device: zynq_sdhci

Manufacturer ID: 2

OEM: 544d

Name: SA08G

Tran Speed: 50000000

Rd Block Len: 512

SD version 2.0

High Capacity: Yes

Capacity: 7.3 GiB

Bus Width: 4-bit

reading uImage

3158312 bytes read in 485 ms (6.2 MiB/s)

reading devicetree.dtb

8172 bytes read in 13 ms (613.3 KiB/s)

## Booting kernel from Legacy Image at 03000000 ...

Image Name:   Linux-3.6.0

Image Type:   ARM Linux Kernel Image (uncompressed)

Data Size:    3158248 Bytes = 3 MiB

Load Address: 00008000

Entry Point:  00008000

Verifying Checksum ... OK

## Flattened Device Tree blob at 02a00000

Booting using the fdt blob at 0x02a00000

Loading Kernel Image ... OK

OK

Loading Device Tree to 1fb4f000, end 1fb53feb ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

Booting Linux on physical CPU 0

Linux version 3.6.0 (ubuntu@ubuntu) (gcc version 4.6.1 (Sourcery CodeBench Lite 2011.09-50) ) #1 SMP PREEMPT Sun Jun 2 13:37:48 CST 2013

CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5387d

CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache

Machine: Xilinx Zynq Platform, model: Xilinx Zynq ZED

bootconsole [earlycon0] enabled

cma: CMA: reserved 40 MiB at 1d000000

Memory policy: ECC disabled, Data cache writealloc

PERCPU: Embedded 7 pages/cpu @c0fcf000 s7872 r8192 d12608 u32768

Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 130048

Kernel command line: console=ttyPS0,115200 root=/dev/mmcblk0p2 rw earlyprintk rootfstype=ext4 rootwait devtmpfs.mount=0

PID hash table entries: 2048 (order: 1, 8192 bytes)

Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)

Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)

Memory: 512MB = 512MB total

Memory: 466556k/466556k available, 57732k reserved, 0K highmem

Virtual kernel memory layout:

vector  : 0xffff0000 - 0xffff1000   (   4 kB)

fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)

vmalloc : 0xe0800000 - 0xff000000   ( 488 MB)

lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)

pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)

modules : 0xbf000000 - 0xbfe00000   (  14 MB)

.text : 0xc0008000 - 0xc0614ce4   (6196 kB)

.init : 0xc0615000 - 0xc063dec0   ( 164 kB)

.data : 0xc063e000 - 0xc06bcb80   ( 507 kB)

.bss : 0xc06bcba4 - 0xc0bc4850   (5152 kB)

Preemptible hierarchical RCU implementation.

RCU lockdep checking is enabled.

Dump stacks of tasks blocking RCU-preempt GP.

RCU restricting CPUs from NR_CPUS=4 to nr_cpu_ids=2.

NR_IRQS:512

MIO pin 11 not assigned(00001760)

xslcr mapped to e0802000

Zynq clock init

timer #0 at e0804000, irq=43

sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 4294967286ms

Console: colour dummy device 80x30

Lock dependency validator: Copyright (c) 2006 Red Hat, Inc., Ingo Molnar

... MAX_LOCKDEP_SUBCLASSES:  8

... MAX_LOCK_DEPTH:          48

... MAX_LOCKDEP_KEYS:        8191

... CLASSHASH_SIZE:          4096

... MAX_LOCKDEP_ENTRIES:     16384

... MAX_LOCKDEP_CHAINS:      32768

... CHAINHASH_SIZE:          16384

memory used by lock dependency info: 3695 kB

per task-struct memory footprint: 1152 bytes

Calibrating delay loop... 1332.01 BogoMIPS (lpj=6660096)

pid_max: default: 32768 minimum: 301

Mount-cache hash table entries: 512

CPU: Testing write buffer coherency: ok

CPU0: thread -1, cpu 0, socket 0, mpidr 80000000

hw perfevents: enabled with ARMv7 Cortex-A9 PMU driver, 7 counters available

Setting up static identity map for 0x3a61a8 - 0x3a61dc

L310 cache controller enabled

l2x0: 8 ways, CACHE_ID 0x410000c8, AUX_CTRL 0x72360000, Cache size: 524288 B

CPU1: Booted secondary processor

CPU1: thread -1, cpu 1, socket 0, mpidr 80000001

Brought up 2 CPUs

SMP: Total of 2 processors activated (2664.03 BogoMIPS).

devtmpfs: initialized

NET: Registered protocol family 16

DMA: preallocated 256 KiB pool for atomic coherent allocations

xgpiops e000a000.gpio: gpio at 0xe000a000 mapped to 0xe080c000

hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.

hw-breakpoint: maximum watchpoint size is 4 bytes.

bio: create slab at 0

SCSI subsystem initialized

usbcore: registered new interface driver usbfs

usbcore: registered new interface driver hub

usbcore: registered new device driver usb

Linux video capture interface: v2.00

Advanced Linux Sound Architecture Driver Version 1.0.25.

Switching to clocksource xttcps_clocksource

NET: Registered protocol family 2

TCP established hash table entries: 16384 (order: 5, 131072 bytes)

TCP bind hash table entries: 16384 (order: 7, 589824 bytes)

TCP: Hash tables configured (established 16384 bind 16384)

TCP: reno registered

UDP hash table entries: 256 (order: 2, 20480 bytes)

UDP-Lite hash table entries: 256 (order: 2, 20480 bytes)

NET: Registered protocol family 1

msgmni has been set to 991

io scheduler noop registered

io scheduler deadline registered

io scheduler cfq registered (default)

xuartps e0001000.uart: failed to get alias id, errno -19

e000console [ttyPS0] enabled, bootconsole disabled

console [ttyPS0] enabled, bootconsole disabled

xdevcfg f8007000.devcfg: ioremap f8007000 to e0814000 with size 1000

[drm] Initialized drm 1.1.0 20060810

platform 6c000000.axi_hdmi: Driver axi-hdmi requests probe deferral

brd: module loaded

loop: module loaded

xqspips e000d000.spi: master is unqueued, this is deprecated

xqspips e000d000.spi: at 0xE000D000 mapped to 0xE0816000, irq=51

libphy: XEMACPS mii bus: probed

xemacps e000b000.eth: pdev->id -1, baseaddr 0xe000b000, irq 54

ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver

ULPI transceiver vendor/product ID 0x0451/0x1507

Found TI TUSB1210 ULPI transceiver.

ULPI integrity check: passed.

xusbps-ehci xusbps-ehci.0: Xilinx PS USB EHCI Host Controller

xusbps-ehci xusbps-ehci.0: new USB bus registered, assigned bus number 1

xusbps-ehci xusbps-ehci.0: irq 53, io mem 0x00000000

xusbps-ehci xusbps-ehci.0: USB 2.0 started, EHCI 1.00

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 1 port detected

Initializing USB Mass Storage driver...

usbcore: registered new interface driver usb-storage

USB Mass Storage support registered.

mousedev: PS/2 mouse device common for all mice

i2c /dev entries driver

usbcore: registered new interface driver uvcvideo

USB Video Class driver (1.1.1)

sdhci: Secure Digital Host Controller Interface driver

sdhci: Copyright(c) Pierre Ossman

sdhci-pltfm: SDHCI platform and OF driver helper

mmc0: Invalid maximum block size, assuming 512 bytes

mmc0: SDHCI controller on e0100000.sdhci [e0100000.sdhci] using ADMA

usbcore: registered new interface driver usbhid

usbhid: USB HID core driver

mmc0: new high speed SDHC card at address 1234

mmcblk0: mmc0:1234 SA08G 7.28 GiB (ro)

mmcblk0: p1 p2

adv7511 0-0039: Failed to add route AIFIN->TMDS

adv7511-hdmi-snd adv7511_hdmi_snd.4:  adv7511 75c00000.axi-spdif-tx mapping ok

INFO: task swapper/0:1 blocked for more than 20 seconds.

"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.

swapper/0       D c03a4a84     0     1      0 0x00000000

[] (__schedule+0x540/0x658) from [] (schedule_timeout+0x18/0x164)

[] (schedule_timeout+0x18/0x164) from [] (wait_for_common+0xe0/0x174)

[] (wait_for_common+0xe0/0x174) from [] (_request_firmware_load+0xe0/0x180)

[] (_request_firmware_load+0xe0/0x180) from [] (request_firmware+0x74/0xb0)

[] (request_firmware+0x74/0xb0) from [] (_process_sigma_firmware+0x1c/0x1b4)

[] (_process_sigma_firmware+0x1c/0x1b4) from [] (process_sigma_firmware_regmap+0x18/0x24)

[] (process_sigma_firmware_regmap+0x18/0x24) from [] (adau17x1_load_firmware+0x58/0x7c)

[] (adau17x1_load_firmware+0x58/0x7c) from [] (adau1761_probe+0x2a8/0x30c)

[] (adau1761_probe+0x2a8/0x30c) from [] (soc_probe_codec+0x18c/0x29c)

[] (soc_probe_codec+0x18c/0x29c) from [] (snd_soc_register_card+0x724/0x10f4)

[] (snd_soc_register_card+0x724/0x10f4) from [] (platform_drv_probe+0x14/0x18)

[] (platform_drv_probe+0x14/0x18) from [] (driver_probe_device+0xb4/0x1ec)

[] (driver_probe_device+0xb4/0x1ec) from [] (__driver_attach+0x68/0x8c)

[] (__driver_attach+0x68/0x8c) from [] (bus_for_each_dev+0x48/0x74)

[] (bus_for_each_dev+0x48/0x74) from [] (bus_add_driver+0x98/0x220)

[] (bus_add_driver+0x98/0x220) from [] (driver_register+0x9c/0x13c)

[] (driver_register+0x9c/0x13c) from [] (do_one_initcall+0x90/0x164)

[] (do_one_initcall+0x90/0x164) from [] (kernel_init+0xf8/0x1b8)

[] (kernel_init+0xf8/0x1b8) from [] (kernel_thread_exit+0x0/0x8)

4 locks held by swapper/0/1:

#0:  (&__lockdep_no_validate__){......}, at: [] __driver_attach+0x40/0x8c

#1:  (&__lockdep_no_validate__){......}, at: [] __driver_attach+0x50/0x8c

#2:  (&card->mutex){+.+.+.}, at: [] snd_soc_register_card+0x274/0x10f4

#3:  (umhelper_sem){++++.+}, at: [] usermodehelper_read_trylock+0x4c/0xb8

INFO: task swapper/0:1 blocked for more than 20 seconds.

"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.

swapper/0       D c03a4a84     0     1      0 0x00000000

[] (__schedule+0x540/0x658) from [] (schedule_timeout+0x18/0x164)

[] (schedule_timeout+0x18/0x164) from [] (wait_for_common+0xe0/0x174)

[] (wait_for_common+0xe0/0x174) from [] (_request_firmware_load+0xe0/0x180)

[] (_request_firmware_load+0xe0/0x180) from [] (request_firmware+0x74/0xb0)

[] (request_firmware+0x74/0xb0) from [] (_process_sigma_firmware+0x1c/0x1b4)

[] (_process_sigma_firmware+0x1c/0x1b4) from [] (process_sigma_firmware_regmap+0x18/0x24)

[] (process_sigma_firmware_regmap+0x18/0x24) from [] (adau17x1_load_firmware+0x58/0x7c)

[] (adau17x1_load_firmware+0x58/0x7c) from [] (adau1761_probe+0x2a8/0x30c)

[] (adau1761_probe+0x2a8/0x30c) from [] (soc_probe_codec+0x18c/0x29c)

[] (soc_probe_codec+0x18c/0x29c) from [] (snd_soc_register_card+0x724/0x10f4)

[] (snd_soc_register_card+0x724/0x10f4) from [] (platform_drv_probe+0x14/0x18)

[] (platform_drv_probe+0x14/0x18) from [] (driver_probe_device+0xb4/0x1ec)

[] (driver_probe_device+0xb4/0x1ec) from [] (__driver_attach+0x68/0x8c)

[] (__driver_attach+0x68/0x8c) from [] (bus_for_each_dev+0x48/0x74)

[] (bus_for_each_dev+0x48/0x74) from [] (bus_add_driver+0x98/0x220)

[] (bus_add_driver+0x98/0x220) from [] (driver_register+0x9c/0x13c)

[] (driver_register+0x9c/0x13c) from [] (do_one_initcall+0x90/0x164)

[] (do_one_initcall+0x90/0x164) from [] (kernel_init+0xf8/0x1b8)

[] (kernel_init+0xf8/0x1b8) from [] (kernel_thread_exit+0x0/0x8)

4 locks held by swapper/0/1:

#0:  (&__lockdep_no_validate__){......}, at: [] __driver_attach+0x40/0x8c

#1:  (&__lockdep_no_validate__){......}, at: [] __driver_attach+0x50/0x8c

#2:  (&card->mutex){+.+.+.}, at: [] snd_soc_register_card+0x274/0x10f4

#3:  (umhelper_sem){++++.+}, at: [] usermodehelper_read_trylock+0x4c/0xb8

adau1761 0-003b: Failed to firmware

zed-adau1761-snd zed_adau1761_snd.7:  adau-hifi 77600000.axi-i2s mapping ok

TCP: cubic registered

NET: Registered protocol family 17

VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4

Registering SWP/SWPB emulation handler

drivers/rtc/hctosys.c: unable to open rtc device (rtc0)

ALSA device list:

#0: HDMI monitor

#1: ZED ADAU1761

No connectors reported connected with modes

[drm] Cannot find any crtc or sizes - going 1024x768

Console: switching to colour frame buffer device 128x48

fb0:  frame buffer device

drm: registered panic notifier

[drm] Initialized axi_hdmi_drm 1.0.0 20120930 on minor 0

VFS: Cannot open root device "mmcblk0p2" or unknown-block(179,2): error -30

Please append a correct "root=" boot option; here are the available partitions:

b300         7639040 mmcblk0  driver: mmcblk

b301          489274 mmcblk0p1 00000000-0000-0000-0000-000000000000

b302         7149581 mmcblk0p2 00000000-0000-0000-0000-000000000000

Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(179,2)

[] (unwind_backtrace+0x0/0xe0) from [] (panic+0x88/0x1e0)

[] (panic+0x88/0x1e0) from [] (mount_block_root+0x238/0x288)

[] (mount_block_root+0x238/0x288) from [] (prepare_namespace+0x160/0x1c0)

[] (prepare_namespace+0x160/0x1c0) from [] (kernel_init+0x178/0x1b8)

[] (kernel_init+0x178/0x1b8) from [] (kernel_thread_exit+0x0/0x8)

CPU1: stopping

[] (unwind_backtrace+0x0/0xe0) from [] (ipi_cpu_stop+0x3c/0x6c)

[] (ipi_cpu_stop+0x3c/0x6c) from [] (handle_IPI+0x68/0xb4)

[] (handle_IPI+0x68/0xb4) from [] (gic_handle_irq+0x54/0x5c)

[] (gic_handle_irq+0x54/0x5c) from [] (__irq_svc+0x44/0x78)

Exception stack(0xdcc77fa0 to 0xdcc77fe8)

7fa0: dcc76000 0001eaf0 dcc77fd8 dcc6e0c0 1cc6006a 00000015 10c0387d c06bcf54

7fc0: 0000406a 413fc090 00000000 00000000 00000000 dcc77fe8 dcc76018 c000e36c

7fe0: 20000013 ffffffff

[] (__irq_svc+0x44/0x78) from [] (default_idle+0x28/0x30)

[] (default_idle+0x28/0x30) from [] (cpu_idle+0x8c/0xe4)

[] (cpu_idle+0x8c/0xe4) from [<0039c134>] (0x39c134)

panic occurred, switching back to text console

今天终于发现了问题的所在,原来是SD卡在使用过程中不小心被锁定了,SD卡处于写保护状态,将SD卡解锁,上面的问题就解决了。而且还发现,SD卡处于写保护状态时,如果直接使用笔记本自带的读卡器访问SD卡,则不可写入;但是如果使用USB接口的读卡器,则可以正常读写SD卡,而我们一直使用的是USB接口的SD卡读卡器,所以之前没有发现这个问题。

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/347568.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

新!详细!win10下MySQL数据库干净卸载安装与配置

微信公众号&#xff1a;创享日记 发送&#xff1a;sqlyog 获取SQLyog客户端安装包 文章目录官方下载卸载清除安装变量配置测试SQLyog客户端下载官方下载 链接直达&#xff1a;点击官方下载 1、选择 2、下载&#xff1a;点击download进入下载页面&#xff0c;选择“No thanks,…

linux系统基本使用教程,Linux系统的基本使用入门

终端&#xff1a;用户与主机交互&#xff0c;必然会使用到的设备&#xff0c;在Linux中也使用文件进行标识物理终端:直接接入到本机的显示器和键盘设备&#xff1a;又叫控制台&#xff1a;console物理终端设备文件&#xff1a;/dev/console虚拟终端&#xff1a;附加在物理终端之…

最基础,MySQL基础查询SELECT

前些天发现了十分不错的人工智能学习网站&#xff0c;通俗易懂&#xff0c;风趣幽默&#xff0c;没有广告&#xff0c;分享给大家&#xff0c;大家可以自行看看。&#xff08;点击跳转人工智能学习资料&#xff09; 1、查询表中字段 USE 要操作的数据库名; SELECT 查询的字段 …

linux编码 form表单,Linux以form表单形式上传文件讲解

先cd到要上传文件的目录下&#xff1a;rootiZ2zee1przeygbuu4rkwvxZ:/usr/local/test# ls1.png DSC_0192.JPG test.apk使用curl -F 或 curl --formcurl --form "fileDSC_0192.JPG" http://ip:port/projectName/busnews/upload*注意&#xff1a;不一定写file&#xff…

有条件了!筛选,MySQL条件查询SELECT-WHERE

1、基本语法 SELECT查询列表 FROM表名 WHERE筛选表达式;2、按条件表达式筛选 条件运算符&#xff1a;>,<,,!,<>,>,< 条件运算符不能判断null。 #在employees表中筛选工资大于12000的员工的所有信息 SELECT* FROMemployees WHEREsalary>12000;3、按逻辑…

rest和rest ful_为什么REST如此重要

rest和rest ful这篇文章致力于REST&#xff0c;一种塑造Web服务的架构风格&#xff0c;以及IT历史上最容易被误解的概念。 这篇文章针对的是正在设计Web服务api的人&#xff0c;他们没有完全了解REST的实际含义。 我想给你个主意。 这篇文章也发给了那些想知道REST意味着什么的…

流利的接口不利于维护

流利的接口 &#xff08;最初由Martin Fowler 创造&#xff09;是一种非常方便的与OOP中的对象进行通信的方式。 它使他们的外墙更易于使用和理解。 但是&#xff0c;它破坏了它们的内部设计&#xff0c;使它们更难以维护。 Marco Pivetta在他的博客文章Fluent Interfaces is E…

c语言初始化字符串 函数 manment,[转载]3.09进程(C语言班最后一天的课程)

1&#xff0c;进程&#xff1a;是容器&#xff0c;是内存上的概念。线程是CPU的概念。2&#xff0c;fork的作用是根据一个现有的进程复制出一个新进程&#xff0c;原来的进程称为父进程(Parents Process)&#xff0c;新进程称为子进程(Child Process)。系统中同时运行着许多进程…

减小程序规模!稀疏数组Sparsearray,数据结构二维数组与稀疏数组转换,Java实现

文章目录基本介绍应用实例基本介绍 当一个数组中大部分元素为0&#xff0c;或者为同一个值的数组时&#xff0c;可以使用稀疏数组来保存该数组。 稀疏数组的处理方法是: ①记录数组一共有几行几列&#xff0c;有多少个不同的值&#xff08;0除外&#xff09;。 ②把具有不同值…

ug弹簧可变性装配_弹簧可配置魔术

ug弹簧可变性装配Spring框架具有几个提供一系列服务的模块&#xff0c;其中许多模块仅可用于托管对象&#xff08;Spring Bean&#xff09;。有关这些服务的一些示例是依赖注入&#xff0c;事务管理&#xff0c;AOP服务等。当我们使用时&#xff0c;一切都很好对象即服务&#…

C语言课程设计报告输出杨辉三角,C语言学习:在屏幕上输出杨辉三角

杨辉三角的规律是&#xff1a;它的两条斜边都是由数字1组成的&#xff0c;而其余的数则是等于它肩上的两个数之和。 代码如下&#xff1a;#include#includeint main(){int i,j,k,arr[10][10]{0};/*arr[11][11]必须初始化&#xff0c;初始化为{0}*/printf("打印出杨辉三角&…

朴实!简单!依你所好,MySQL排序查询ORDER BY

1、基本语法 SELECT查询列表 FROM表 #可选&#xff08;WHERE ...&#xff09; ORDER BY排序列表 DESC/ASC;升序是ASC或者不写&#xff0c;降序是DESC 2、案例一&#xff1a;按字段&#xff08;*代表全部&#xff09; SELECT* FROMemployees ORDER BYsalary DESC;3、案例二&am…

使用一个命令执行单个Java源文件

JDK增强提案 &#xff08; JEP &#xff09; 草案于2017年末创建&#xff0c;名为“ 启动单文件源代码程序 ”&#xff08;其相关的JDK问题为JDK-8192920 &#xff09;。 顾名思义&#xff0c;该JEP草案旨在“增强Java启动器以支持运行作为Java源代码的单个文件提供的程序。” …

习惯性朴实简单!一起学习MySQL常见单行函数,字符数学日期流程控制

文章目录一、字符函数二、数学函数三、日期函数四、其他函数五、流程控制函数一、字符函数 1、大小写控制函数 ①UPPER()&#xff1a;转换成大写 SELECT UPPER(Hello);②LOWER()&#xff1a;转换成小写 SELECT LOWER(Hello);2、字符控制函数 ①LENGTH()&#xff1a;获取参数…

c语言程序设计陈雪芳,东莞理工学院C语言课程设计.doc

東莞理工學院C语言程序设计课程设计报告书院系名称 机械工程学院专业班级 2013级机械设计制造及其自动化1班组长成员指导教师 陈雪芳完成时间 2014年6月1日目 录1、系统功能及任务描述………………………..1.1系统总体功能描述………………………….1.2主要任务描述…………………

不可上位!数据结构队列,老实排队,Java实现数组模拟队列及可复用环形队列

文章目录队列简介数组模拟队列&#xff08;无法复用&#xff09;数组模拟环形队列&#xff08;可复用&#xff09;队列简介 队列是一个有序列表&#xff0c;可以用数组或是链表来实现。 遵循先入先出的原则。即先存入队列的数据&#xff0c;先取出&#xff0c;后存入的后取出…

c语言循环与数组训练题,C语言循环数组练习题解读.doc

循环数组练习题一&#xff0e;选择题1&#xff0e;for(i0;i<10;i); 结束后&#xff0c; i 的值是&#xff1b; BA9B10C11D122&#xff0e;下面程序的循环次数是&#xff1a;Dint k0;while(k<10){if(k<1)continue;if(k5)break;k;}A.5B6C4D 死循环&#xff0c;不能确定循…

Java更快地对基元数组进行排序?

看起来Java的原语排序数组在不久的将来可能会提高性能。 弗拉基米尔雅罗斯拉夫斯基&#xff08;Vladimir Yaroslavskiy&#xff09;已在core-libs-dev邮件列表中发布了一条消息 &#xff0c;标题为“ Dual-Pivot Quicksort的新优化版本 ”&#xff0c;其中Yaroslavskiy撰写了“…

多对一!分组查询!MySQL分组函数,聚合函数,分组查询

文章目录一、简单使用二、搭配DISTINCT去重三、COUNT()详细介绍四、分组查询一、简单使用 SUM&#xff1a;求和&#xff08;一般用于处理数值型&#xff09; AVG&#xff1a;平均&#xff08;一般用于处理数值型&#xff09; MAX&#xff1a;最大&#xff08;也可以用于处理字…

华工网络教育C语言校考答案,计算机应用基础(统考)随堂练习2017秋华工答案.docx...

计算机应用基础(统考)随堂练习第一章计算机基础知识计算机能直接识别并执行的语言是 ______。A. 汇编语言B.自然语言C.机器语言D.高级语言答题&#xff1a;A. B. C. D.参考答案&#xff1a; C计算机存储容量的基本单位是 _____。A. 赫兹B.字节( Byte)C.位 (bit)D. 波特答题&…