Protocol error (Page.printToPDF): PrintToPDF is not implemented

本文指出在使用Puppeteer时,若想通过Page.printToPDF()创建PDF,需确保以无头模式(headless: true)启动Chrome。当前Chrome仅支持无头模式下的PDF导出。

Protocol error (Page.printToPDF): PrintToPDF is not implemented

查看官方文档pdf > 目前仅支持无头模式的 Chrome
在这里插入图片描述

puppeteer.launch({
		// headless <boolean> 是否以 无头模式 运行浏览器。默认是 true,除非 devtools 选项是 true。
		headless: true,// 即该参数要为true才能使用pdf
import UIKit import SnapKit // MARK: - DeviceListNewViewController class DeviceListNewViewController: SurveillanceCommonTableController { // MARK: - 子视图声明 private lazy var tabScrollView: UIScrollView = { let scrollView = UIScrollView() scrollView.showsHorizontalScrollIndicator = false scrollView.backgroundColor = UIColor(white: 0.95, alpha: 1.0) scrollView.layer.cornerRadius = 8 scrollView.clipsToBounds = true return scrollView }() private let tabButtonTitles = ["所有设备", "收藏页面", "站点选择"] private var selectedTabIndex = 0 private var tabButtons: [UIButton] = [] // 吸顶头部 private lazy var stickyHeader: UIView = { let header = UIView() header.backgroundColor = tpbColorBackground() return header }() private lazy var backButton: UIButton = { let btn = UIButton(type: .custom) btn.setTitle("←", for: .normal) btn.setTitleColor(UIColor.blue, for: .normal) btn.contentEdgeInsets = UIEdgeInsets(top: 8, left: 8, bottom: 8, right: 8) btn.addTarget(self, action: #selector(onBackTapped), for: .touchUpInside) return btn }() private lazy var locationButton: UIButton = { let btn = UIButton(type: .custom) btn.setTitle("📍", for: .normal) btn.setTitleColor(UIColor.blue, for: .normal) btn.contentEdgeInsets = UIEdgeInsets(top: 8, left: 8, bottom: 8, right: 8) btn.addTarget(self, action: #selector(onLocationTapped), for: .touchUpInside) return btn }() private lazy var titleLabel: UILabel = { let label = UILabel() label.text = "设备列表" label.font = UIFont.systemFont(ofSize: 18, weight: .medium) label.textColor = tpbColorTextPrimary() label.textAlignment = .center return label }() private lazy var searchButton: UIButton = { let btn = UIButton(type: .custom) btn.setTitle("🔍", for: .normal) btn.setTitleColor(UIColor.blue, for: .normal) btn.contentEdgeInsets = UIEdgeInsets(top: 8, left: 8, bottom: 8, right: 8) btn.addTarget(self, action: #selector(onSearchTapped), for: .touchUpInside) return btn }() private lazy var separatorLine: UIView = { let line = UIView() line.backgroundColor = UIColor(red: 200/255, green: 200/255, blue: 200/255, alpha: 0.3) return line }() // 横向分页容器 private lazy var deviceCollectionView: UICollectionView = { let layout = UICollectionViewFlowLayout() layout.scrollDirection = .horizontal layout.itemSize = CGSize(width: UIScreen.main.bounds.width - 32, height: 400) layout.minimumLineSpacing = 16 layout.sectionInset = UIEdgeInsets(top: 0, left: 16, bottom: 0, right: 16) let cv = UICollectionView(frame: .zero, collectionViewLayout: layout) cv.backgroundColor = .clear cv.isPagingEnabled = true cv.showsHorizontalScrollIndicator = false cv.bounces = true cv.delegate = self cv.dataSource = self cv.register(DevicePageCollectionViewCell.self, forCellWithReuseIdentifier: "DevicePageCell") return cv }() // 页面控制器指示器 private lazy var pageControl: UIPageControl = { let pc = UIPageControl() pc.numberOfPages = 3 pc.currentPage = 0 pc.pageIndicatorTintColor = UIColor(white: 0.7, alpha: 1.0) pc.currentPageIndicatorTintColor = UIColor.blue pc.hidesForSinglePage = true return pc }() // MARK: - 生命周期 override func viewDidLoad() { super.viewDidLoad() self.tableView.contentInsetAdjustmentBehavior = .never reloadData() } override func viewWillAppear(_ animated: Bool) { super.viewWillAppear(animated) navigationController?.setNavigationBarHidden(true, animated: false) } override func tpbSetupSubviews() { super.tpbSetupSubviews() // 添加吸顶栏 view.addSubview(stickyHeader) stickyHeader.addSubview(backButton) stickyHeader.addSubview(locationButton) stickyHeader.addSubview(titleLabel) stickyHeader.addSubview(searchButton) stickyHeader.addSubview(separatorLine) createTabButtons() layoutTabButtonsInScrollView() } override func tpbMakeConstraint() { stickyHeader.snp.makeConstraints { make in make.top.equalTo(view.safeAreaLayoutGuide.snp.top) make.leading.trailing.equalToSuperview() make.height.equalTo(50) } backButton.snp.remakeConstraints { make in make.leading.equalTo(stickyHeader).offset(16) make.centerY.equalTo(stickyHeader) make.width.greaterThanOrEqualTo(30) } locationButton.snp.remakeConstraints { make in make.leading.equalTo(backButton.snp.trailing).offset(8) make.centerY.equalTo(backButton) make.size.equalTo(30) } titleLabel.snp.remakeConstraints { make in make.centerX.equalToSuperview() make.centerY.equalTo(backButton) } searchButton.snp.remakeConstraints { make in make.trailing.equalTo(stickyHeader).offset(-16) make.centerY.equalTo(backButton) make.width.greaterThanOrEqualTo(30) } separatorLine.snp.makeConstraints { make in make.height.equalTo(1 / UIScreen.main.scale) make.leading.trailing.bottom.equalToSuperview() } tableView.snp.remakeConstraints { make in make.top.equalTo(stickyHeader.snp.bottom).offset(10) make.leading.trailing.bottom.equalToSuperview() } } // MARK: - Tab 操作 private func createTabButtons() { tabButtons = tabButtonTitles.enumerated().map { index, title in let btn = UIButton(type: .custom) btn.tag = index btn.setTitle(title, for: .normal) btn.titleLabel?.font = UIFont.systemFont(ofSize: 14) btn.setTitleColor(UIColor(white: 0.4, alpha: 1.0), for: .normal) btn.setTitleColor(UIColor.blue, for: .selected) btn.layer.borderWidth = 1 btn.layer.borderColor = UIColor(white: 0.85, alpha: 1.0).cgColor btn.layer.cornerRadius = 20 btn.contentEdgeInsets = UIEdgeInsets(top: 8, left: 16, bottom: 8, right: 16) btn.addTarget(self, action: #selector(onTabTapped(_:)), for: .touchUpInside) return btn } updateTabSelection(index: selectedTabIndex) } @objc private func onTabTapped(_ sender: UIButton) { guard sender.tag != selectedTabIndex else { return } updateTabSelection(index: sender.tag) scrollToPage(index: sender.tag) } private func updateTabSelection(index: Int) { self.selectedTabIndex = index for (i, btn) in tabButtons.enumerated() { btn.isSelected = (i == index) } pageControl.currentPage = index DispatchQueue.main.async { self.deviceCollectionView.scrollToItem(at: IndexPath(item: index, section: 0), at: .centeredHorizontally, animated: true) } } private func layoutTabButtonsInScrollView() { tabScrollView.subviews.forEach { $0.removeFromSuperview() } var previousButton: UIButton? for button in tabButtons { tabScrollView.addSubview(button) button.snp.makeConstraints { make in make.centerY.equalToSuperview() make.height.equalTo(36) if let prev = previousButton { make.leading.equalTo(prev.snp.trailing).offset(8) } else { make.leading.equalTo(tabScrollView).offset(16) } make.width.greaterThanOrEqualTo(90) make.width.equalTo(button.titleLabel!.snp.width).offset(32).priority(.low) } previousButton = button } if let lastBtn = previousButton { lastBtn.snp.makeConstraints { make in make.trailing.equalTo(tabScrollView).offset(-16) } } tabScrollView.layoutIfNeeded() } // MARK: - 创建横向滑动设备区域(单个 cell 内容) private func createHorizontalScrollableDeviceView() -> UIView { let containerView = UIView() containerView.backgroundColor = .clear // Collection View deviceCollectionView.translatesAutoresizingMaskIntoConstraints = false containerView.addSubview(deviceCollectionView) // Page Control pageControl.translatesAutoresizingMaskIntoConstraints = false containerView.addSubview(pageControl) NSLayoutConstraint.activate([ deviceCollectionView.topAnchor.constraint(equalTo: containerView.topAnchor), deviceCollectionView.leadingAnchor.constraint(equalTo: containerView.leadingAnchor), deviceCollectionView.trailingAnchor.constraint(equalTo: containerView.trailingAnchor), deviceCollectionView.height.constraint(equalToConstant: 400), pageControl.topAnchor.constraint(equalTo: deviceCollectionView.bottomAnchor, constant: 8), pageControl.centerX.constraint(equalTo: containerView.centerXAnchor), pageControl.bottomAnchor.constraint(equalTo: containerView.bottomAnchor), ]) return containerView } // 主动滚动到某一页 private func scrollToPage(index: Int) { let indexPath = IndexPath(item: index, section: 0) deviceCollectionView.scrollToItem(at: indexPath, at: .centeredHorizontally, animated: true) } // MARK: - 刷新设备列表(现在只刷新一次,作为单个 cell 插入) private func refreshDeviceListSection() { let cellModel = TPBBaseTableCellModel.customContent(with: createHorizontalScrollableDeviceView()) cellModel.height = TPBTableElementHeight.customHeight(440) // 400 + 8 + 32 let section = TPBTableSectionModel() section.cellModelArray = [cellModel] if sectionArray.count > 1 { sectionArray[1] = section } else { sectionArray.append(section) } tableView.reloadData() } // MARK: - 加载初始数据 private func reloadData() { var tempSectionArray = [TPBTableSectionModel]() // Section 0: 卡片信息 let section0 = TPBTableSectionModel() var cellModels = [TPBBaseTableCellModel]() // 设备总数视图 let deviceCountView = createDeviceCountView() let deviceCountCellModel = TPBBaseTableCellModel.customContent(with: deviceCountView) deviceCountCellModel.height = TPBTableElementHeight.customHeight(60) cellModels.append(deviceCountCellModel) // 存储空间视图 let storageView = createStorageUsageView() let storageCellModel = TPBBaseTableCellModel.customContent(with: storageView) storageCellModel.height = TPBTableElementHeight.customHeight(60) cellModels.append(storageCellModel) // Tab 区域 let tabView = createTabContainerView() let tabCellModel = TPBBaseTableCellModel.customContent(with: tabView) tabCellModel.height = TPBTableElementHeight.customHeight(72) cellModels.append(tabCellModel) section0.cellModelArray = cellModels tempSectionArray.append(section0) // 初始化设备列表区域(单 cell 多页) refreshDeviceListSection() // 合并 sections sectionArray = tempSectionArray + Array(sectionArray.dropFirst(max(0, sectionArray.count - 1))) tableView.reloadData() } // MARK: - 自定义 View 构建函数 /// 获取背景色(兼容 iOS 12) private func tpbColorBackground() -> UIColor { if #available(iOS 13, *) { return UIColor.systemBackground } else { return UIColor(white: 1.0, alpha: 1.0) } } /// 获取主文本色(兼容 iOS 12) private func tpbColorTextPrimary() -> UIColor { if #available(iOS 13, *) { return UIColor.label } else { return UIColor.black } } private func createDeviceCountView() -> UIView { let view = UIView() view.backgroundColor = .clear let label = UILabel() label.text = "设备总数:32 台" label.font = UIFont.systemFont(ofSize: 16, weight: .regular) label.textColor = tpbColorTextPrimary() label.translatesAutoresizingMaskIntoConstraints = false view.addSubview(label) label.snp.makeConstraints { make in make.centerY.equalTo(view) make.leading.equalTo(view).offset(16) } return view } private func createStorageUsageView() -> UIView { let view = UIView() view.backgroundColor = .clear let label = UILabel() label.text = "已用存储:1.2 TB / 5 TB" label.font = UIFont.systemFont(ofSize: 16, weight: .regular) label.textColor = tpbColorTextPrimary() label.translatesAutoresizingMaskIntoConstraints = false view.addSubview(label) label.snp.makeConstraints { make in make.centerY.equalTo(view) make.leading.equalTo(view).offset(16) } return view } private func createTabContainerView() -> UIView { let container = UIView() container.backgroundColor = .clear tabScrollView.translatesAutoresizingMaskIntoConstraints = false container.addSubview(tabScrollView) tabScrollView.snp.makeConstraints { make in make.leading.equalTo(container).offset(16) make.trailing.equalTo(container).offset(-16) make.centerY.equalTo(container) make.height.equalTo(44) } return container } // MARK: - Action 回调 @objc private func onBackTapped() { navigationController?.popViewController(animated: true) } @objc private func onLocationTapped() { print("定位按钮点击") } @objc private func onSearchTapped() { print("搜索按钮点击") } } // MARK: - UICollectionViewDataSource & Delegate extension DeviceListNewViewController: UICollectionViewDataSource, UICollectionViewDelegate { func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { return 3 } func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "DevicePageCell", for: indexPath) as! DevicePageCollectionViewCell switch indexPath.item { case 0: let devices = (0..<30).map { "所有设备 \($0 + 1)" } cell.configure(with: "所有设备", deviceNames: devices) case 1: let favorites = (0..<10).map { "收藏设备 \($0 + 1)" } cell.configure(with: "收藏页面", deviceNames: favorites) case 2: let sites = ["站点 A", "站点 B", "站点 C", "站点 D"] cell.configure(with: "站点选择", deviceNames: sites) default: break } return cell } func scrollViewDidEndDecelerating(_ scrollView: UIScrollView) { if scrollView === deviceCollectionView { let page = Int(scrollView.contentOffset.x / scrollView.bounds.width) updateTabSelection(index: page) } } } // MARK: - DevicePageCollectionViewCell(每一页的内容) class DevicePageCollectionViewCell: UICollectionViewCell { private let titleLabel = UILabel() private let innerStackView = UIStackView() private var deviceViews: [UIView] = [] override init(frame: CGRect) { super.init(frame: frame) setupUI() } required init?(coder: NSCoder) { fatalError("init(coder:) has not been implemented") } private func setupUI() { backgroundColor = UIColor(white: 0.95, alpha: 1.0) layer.cornerRadius = 12 clipsToBounds = true // 标题 titleLabel.font = UIFont.systemFont(ofSize: 18, weight: .bold) titleLabel.textAlignment = .center titleLabel.textColor = UIColor(red: 0.0, green: 0.4, blue: 1.0, alpha: 1.0) // 内部堆叠视图 innerStackView.axis = .vertical innerStackView.spacing = 10 innerStackView.distribution = .fillProportionally // 布局 addSubview(titleLabel) addSubview(innerStackView) titleLabel.translatesAutoresizingMaskIntoConstraints = false innerStackView.translatesAutoresizingMaskIntoConstraints = false NSLayoutConstraint.activate([ titleLabel.topAnchor.constraint(equalTo: topAnchor, constant: 20), titleLabel.leadingAnchor.constraint(equalTo: leadingAnchor, constant: 16), titleLabel.trailingAnchor.constraint(equalTo: trailingAnchor, constant: -16), innerStackView.topAnchor.constraint(equalTo: titleLabel.bottomAnchor, constant: 16), innerStackView.leadingAnchor.constraint(equalTo: leadingAnchor, constant: 16), innerStackView.trailingAnchor.constraint(equalTo: trailingAnchor, constant: -16), innerStackView.bottomAnchor.constraint(equalTo: bottomAnchor, constant: -16) ]) } func configure(with title: String, deviceNames: [String]) { titleLabel.text = title // 清除旧视图 for view in deviceViews { innerStackView.removeArrangedSubview(view) view.removeFromSuperview() } deviceViews.removeAll() // 添加新设备项 for name in deviceNames { let deviceView = createDeviceItemView(name: name) innerStackView.addArrangedSubview(deviceView) deviceViews.append(deviceView) } } private func createDeviceItemView(name: String) -> UIView { let view = UIView() view.backgroundColor = .white view.layer.cornerRadius = 8 view.layer.borderWidth = 1 view.layer.borderColor = UIColor(red: 0.0, green: 0.4, blue: 1.0, alpha: 0.3).cgColor let label = UILabel() label.text = name label.font = UIFont.systemFont(ofSize: 16, weight: .medium) label.textColor = UIColor(red: 0.0, green: 0.4, blue: 1.0, alpha: 1.0) label.textAlignment = .center view.addSubview(label) label.translatesAutoresizingMaskIntoConstraints = false NSLayoutConstraint.activate([ label.centerX.constraint(equalTo: view.centerXAnchor), label.centerY.constraint(equalTo: view.centerYAnchor) ]) return view } } // MARK: - DeviceListCell(保留原类用于其他场景或过渡) class DeviceListCell: UICollectionViewCell { private let titleLabel = UILabel() override init(frame: CGRect) { super.init(frame: frame) setupUI() } required init?(coder aDecoder: NSCoder) { super.init(coder: aDecoder) setupUI() } private func setupUI() { backgroundColor = UIColor(red: 0.0, green: 0.4, blue: 1.0, alpha: 0.1) layer.borderColor = UIColor(red: 0.0, green: 0.4, blue: 1.0, alpha: 1.0).cgColor layer.borderWidth = 1 layer.cornerRadius = 8 clipsToBounds = true titleLabel.font = UIFont.systemFont(ofSize: 16, weight: .medium) titleLabel.textColor = UIColor(red: 0.0, green: 0.4, blue: 1.0, alpha: 1.0) titleLabel.textAlignment = .center titleLabel.numberOfLines = 1 titleLabel.translatesAutoresizingMaskIntoConstraints = false contentView.addSubview(titleLabel) titleLabel.snp.makeConstraints { make in make.center.equalTo(contentView) make.leading.greaterThanOrEqualTo(contentView).offset(8) make.trailing.lessThanOrEqualTo(contentView).offset(-8) } } func configure(with title: String) { titleLabel.text = title } override func prepareForReuse() { super.prepareForReuse() titleLabel.text = nil } }这里面都使用snapkit布局,而且出现了错误:Value of type 'UICollectionView' has no member 'height'。func scrollViewDidEndDecelerating(_ scrollView: UIScrollView) { if scrollView === deviceCollectionView { let page = Int(scrollView.contentOffset.x / scrollView.bounds.width) updateTabSelection(index: page) } } Overriding declaration requires an 'override' keyword
最新发布
12-04
E:CD IPL g0815cea D-0 BIST-128MB: OK IPL_CUST g0815cea D-0 U-Boot 2021.10 (Aug 29 2025 - 11:49:41 +0800) SoC: SigmaStar iford Model: IFORD Version: I###g7a33163 DRAM: 126 MiB WDT: Not found! Flash: SPI 54M [FLASH] Device id is 0xa1 0x40 0x18 [SPINOR] ReadData = 0x6b [SPINOR] Dummy = 0x8 [SPINOR] pageProgram = 0x2 [FLASH] BDMA mode [SPINOR] complement = 0x0 [SPINOR] top/buttom = 0x0 [SPINOR] blocks = 0x0 [SPINOR] SRP0 = 0x0 [SPINOR] SRP1 = 0x0 [FLASH] End flash init. spi clk already initialized mtd .name = nor0, .size = 0x01000000 (16MiB) .erasesize = 0x00001000 . Detected nor0 with total size 16 MiB 16 MiB MMC: Fail to get pad(0x0) ip(0x0_8) form padmux ! Fail to get pad(0x0) ip(0x1_8) form padmux ! MSC: 1, MSC: 0 Loading Environment from SPIFlash... ENV: offset = 0x4f000 size = 0x1000 OK In: serial Out: serial Err: serial Net: MAC Address 00:70:95:00:00:01 Auto-Negotiation... Link Status Speed:100 Full-duplex:1 sstar_emac Hit any key to stop autoboot: 0 ## Booting kernel from Legacy Image at 22000000 ... Image Name: MVX4##I###g599305bKL_LX510##[BR: Image Type: ARM Linux Kernel Image (lzma compressed) Data Size: 1908816 Bytes = 1.8 MiB Load Address: 20008000 Entry Point: 20008000 Verifying Checksum ... OK Uncompressing Kernel Image [XZ] !!!reserved 0x22000000 length=0x 1000000 for xz!! XZ: uncompressed size=0x3e77c0, ret=7 Starting kernel ... early_atags_to_fdt() success Booting Linux on physical CPU 0x0 Linux version 5.10.117 (longxing.nie@szl3bc12806) (arm-sigmastar-linux-uclibcgnueabihf-9.1.0-gcc (crosstool-NG 1.24.0) 9.1.0, GNU ld (crosstool-NG 1.24.0) 2.32) #48 SMP PREEMPT Fri Aug 29 16:29:53 CST 2025 CPU: ARMv7 Processor [411fd010] revision 0 (ARMv7), cr=50c5383d CPU: div instructions available: patching division code CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache early_atags_to_fdt() success OF: fdt: Machine model: IFORD SSC029C-S01A LXmem is 0x8000000 PHYS_OFFSET is 0x20000000 Add mem start 0x20000000 size 0x8000000!!!! LX_MEM = 0x20000000, 0x8000000 LX_MEM2 = 0x0, 0x0 LX_MEM3 = 0x0, 0x0 MMU_MEM = 0x0, 0x0 EMAC_LEN= 0x0 DRAM_LEN= 0x0 Memory policy: Data cache writealloc Reserved memory: bypass cma0 node, using cmdline CMA params instead OF: reserved mem: node cma0 compatible matching fail no any mmap reserved deal_with_reserve_mma_heap memblock_reserve success mma_config[0].reserved_start= 0x24000000 size:4000000 cma: Reserved 2 MiB at 0x23e00000 Zone ranges: Normal [mem 0x0000000020000000-0x0000000023ffffff] Movable zone start for each node Early memory node ranges node 0: [mem 0x0000000020000000-0x0000000023ffffff] Initmem setup node 0 [mem 0x0000000020000000-0x0000000023ffffff] percpu: Embedded 13 pages/cpu s22872 r8192 d22184 u53248 Built 1 zonelists, mobility grouping on. Total pages: 16256 Kernel command line: console=ttyS0,115200n8r root=/dev/mtdblock3 ro init=/linuxrc LX_MEM=0x8000000 mma_heap=mma_heap_name0,miu=0,sz=0x4000000 mma_memblock_remove=1 cma=2M mtdparts=nor0:0x4F000(BOOT),0x1000(ENV),0x300000(KERNEL),0x220000(rootfs),0xB0000(MISC),0x4D0000(miservice),0x500000(customer) nohz=off printk: log_buf_len individual max cpu contribution: 32768 bytes printk: log_buf_len total cpu_extra contributions: 32768 bytes printk: log_buf_len min size: 32768 bytes printk: log_buf_len: 65536 bytes printk: early log buf free: 30484(93%) Dentry cache hash table entries: 8192 (order: 3, 32768 bytes, linear) Inode-cache hash table entries: 4096 (order: 2, 16384 bytes, linear) mem auto-init: stack:off, heap alloc:off, heap free:off Memory: 58228K/65536K available (2237K kernel code, 373K rwdata, 1080K rodata, 148K init, 118K bss, 5260K reserved, 2048K cma-reserved) SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1 rcu: Preemptible hierarchical RCU implementation. rcu: RCU restricting CPUs from NR_CPUS=4 to nr_cpu_ids=2. Trampoline variant of Tasks RCU enabled. rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies. rcu: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2 NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16 GICv3: 192 SPIs implemented GICv3: 0 Extended SPIs implemented GICv3: Distributor has no Range Selector support GICv3: 16 PPIs implemented GICv3: CPU0: found redistributor 0 region 0:0x16040000 sstar_init_main_intc: np->name=sstar_main_intc, parent=gic sstar_pm_main_init: np->name=sstar_pm_main_intc, parent=sstar_main_intc sstar_pm_gpi_init: np->name=sstar_pm_gpi_intc, parent=sstar_main_intc sstar_gpi_init: np->name=sstar_gpi_intc, parent=sstar_main_intc random: get_random_bytes called from start_kernel+0x20d/0x3a4 with crng_init=0 arch_timer: cp15 timer(s) running at 6.00MHz (virt). clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x1623fa770, max_idle_ns: 440795202238 ns sched_clock: 56 bits at 6MHz, resolution 166ns, wraps every 4398046511055ns Switching to timer-based delay loop, resolution 166ns printk: console [ttyS0] enabled Calibrating delay loop (skipped), value calculated using timer frequency.. 12.00 BogoMIPS (lpj=60000) pid_max: default: 4096 minimum: 301 Mount-cache hash table entries: 1024 (order: 0, 4096 bytes, linear) Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes, linear) CPU: Testing write buffer coherency: ok CPU0: thread -1, cpu 0, socket 0, mpidr 80000000 Setting up static identity map for 0x20008280 - 0x200082d4 rcu: Hierarchical SRCU implementation. smp: Bringing up secondary CPUs ... GICv3: CPU1: found redistributor 1 region 0:0x16060000 CPU1: thread -1, cpu 1, socket 0, mpidr 80000001 smp: Brought up 1 node, 2 CPUs SMP: Total of 2 processors activated (24.00 BogoMIPS). CPU: All CPU(s) started in SVC mode. devtmpfs: initialized VFP support v0.3: implementor 41 architecture 3 part 40 variant 1 rev 2 clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns futex hash table entries: 16 (order: -2, 1024 bytes, linear) NET: Registered protocol family 16 DMA: preallocated 256 KiB pool for atomic coherent allocations Version : MVX4##I###g599305bKL_LX510##[BR:dev_i6dw_bringup]#XVM irq: IRQ43: trimming hierarchy from :soc:sstar_main_intc irq: IRQ44: trimming hierarchy from :soc:sstar_main_intc irq: IRQ45: trimming hierarchy from :soc:sstar_main_intc irq: IRQ46: trimming hierarchy from :soc:sstar_main_intc GPIO: probe end [Padmux]reset PAD48(reg 0x3f00:52; mask0x300) t0 I2C0_MODE_4 (org: PM_SDIO_MODE_3) Do qos-initialize [sstar_update_dq_init] clocksource: Switched to clocksource arch_sys_counter NET: Registered protocol family 2 IP idents hash table entries: 2048 (order: 2, 16384 bytes, linear) tcp_listen_portaddr_hash hash table entries: 256 (order: 0, 6144 bytes, linear) TCP established hash table entries: 1024 (order: 0, 4096 bytes, linear) TCP bind hash table entries: 1024 (order: 2, 20480 bytes, linear) TCP: Hash tables configured (established 1024 bind 1024) UDP hash table entries: 128 (order: 0, 6144 bytes, linear) UDP-Lite hash table entries: 128 (order: 0, 6144 bytes, linear) NET: Registered protocol family 1 Initialise system trusted keyrings workingset: timestamp_bits=30 max_order=14 bucket_order=0 squashfs: version 4.0 (2009/01/31) Phillip Lougher jffs2: version 2.2. © 2001-2006 Red Hat, Inc. Key type asymmetric registered Asymmetric key parser 'x509' registered io scheduler mq-deadline registered i2c /dev entries driver failed to get uart clk_mcu failed to get uart clk_mcu [SSTAR_PM_GPI_INTC] hw:59 -> v:90 irq: IRQ90: trimming hierarchy from :soc:sstar_main_intc please set rtc timer (hwclock -w) sstar,rtcpwc 1f006800.rtcpwc: registered as rtc0 sstar,rtcpwc 1f006800.rtcpwc: setting system clock to 1970-01-01T00:00:00 UTC (0) input: rtcpwc as /devices/platform/soc/1f006800.rtcpwc/input/input0 [Padmux]reset PAD48(reg 0x3f00:5; mask0x8) t0 I2C0_MODE_4 (org: GPIO_MODE) [Padmux]reset PAD49(reg 0x3f00:6; mask0x8) t0 I2C0_MODE_4 (org: GPIO_MODE) [Padmux]reset PAD3(reg 0x103e00:3; mask0x8) t0 I2C1_MODE_1 (org: GPIO_MODE) [Padmux]reset PAD0(reg 0x103e00:0; mask0x8) t0 I2C1_MODE_1 (org: GPIO_MODE) [Padmux]reset PAD65(reg 0x3f00:16; mask0x8) t0 PM_I2CM0_MODE_1 (org: GPIO_MODE) [Padmux]reset PAD66(reg 0x3f00:17; mask0x8) t0 PM_I2CM0_MODE_1 (org: GPIO_MODE) cryptodev: driver 1.10(a1e738a) loaded. random: fast init done ms_cpufreq_init 471 SIDD: 0x62 OSC:0xea random: crng init done ms_cpufreq_init 472 SIDD Thres: 0x0 OSC Thres:0x978 [ms_cpufreq_init] Current clk=800000048 SPI 54M [FLASH] Device id is 0xa1 0x40 0x18 [SPINOR] ReadData = 0x6b [SPINOR] Dummy = 0x8 [SPINOR] pageProgram = 0x2 [FLASH] BDMA mode [SPINOR] complement = 0x0 [SPINOR] top/buttom = 0x0 [SPINOR] blocks = 0x0 [SPINOR] SRP0 = 0x0 [SPINOR] SRP1 = 0x0 [FLASH] End flash init. sstar_spinor_probe: 7mtd .name = nor0, .size = 0x01000000 (16MiB) .erasesize = 0x00001000 .numeraseregions = 0 7 cmdlinepart partitions found on MTD device nor0 Creating 7 MTD partitions on "nor0": 0x000000000000-0x00000004f000 : "BOOT" 0x00000004f000-0x000000050000 : "ENV" 0x000000050000-0x000000350000 : "KERNEL" 0x000000350000-0x000000570000 : "rootfs" 0x000000570000-0x000000620000 : "MISC" 0x000000620000-0x000000af0000 : "miservice" 0x000000af0000-0x000000ff0000 : "customer" error, PmInfoSize :0 < 64 get mbx pm info fail,dump log disable ss_mbx_cdev_init[159]: mbx_cdev init. [sstar_pm_init] MIU0_BASE=20000000 [sstar_pm_init] resume_entry=0x2000ff2c, suspend_imi_vbase=0XC4876000 Registering SWP/SWPB emulation handler Loading compiled-in X.509 certificates OF: fdt: not creating '/sys/firmware/fdt': CRC check failed clk: Not disabling unused clocks VFS: Mounted root (squashfs filesystem) readonly on device 31:3. devtmpfs: mounted Kernel memory protection not selected by kernel config. Run /linuxrc as init process process '/bin/busybox' started with executable stack net.core.rmem_default = 163840 net.core.rmem_max = 163840 net.core.wmem_default = 524288 net.core.wmem_max = 1048576 net.ipv4.tcp_mem = 924 1232 1848 net.ipv4.tcp_rmem = 4096 87380 325120 net.ipv4.tcp_wmem = 4096 131072 393216 /etc/init.d/rcS: line 16: resize2fs: not found /etc/init.d/rcS: line 17: resize2fs: not found fuse: device not found, try 'modprobe fuse' first insmod: can't read '/config/modules/5.10/sstar_rtcpwc.ko': No such file or directory insmod: can't read '/config/modules/5.10/sstar_iic.ko': No such file or directory insmod: can't read '/config/modules/5.10/sstar_timer.ko': No such file or directory insmod: can't read '/config/modules/5.10/scsi_mod.ko': No such file or directory insmod: can't read '/config/modules/5.10/usb-storage.ko': No such file or directory insmod: can't read '/config/modules/5.10/sstar_pwm.ko': No such file or directory insmod: can't read '/config/modules/5.10/sstar_mspi.ko': No such file or directory insmod: can't read '/config/modules/5.10/mdrv_sar.ko': No such file or directory insmod: can't read '/config/modules/5.10/drv_crypto.ko': No such file or directory insmod: can't read '/config/modules/5.10/sd_mod.ko': No such file or directory insmod: can't read '/config/modules/5.10/gyro.ko': No such file or directory 分析日志,程序是nor flash还是nand flash
09-23
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值