arch/arm/crypto/aes-ce-core.S:467: Error: selected processor does not support `movw ip,:lower16:.Lcts_permute_table' in ARM mode
by kbuild test robot
Hi Ard,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 97f9a3c4eee55b0178b518ae7114a6a53372913d
commit: c61b1607ed4fbbf2ba7c86f29768cff44a1a88f8 crypto: arm/aes-ce - implement ciphertext stealing for XTS
date: 3 weeks ago
config: arm-allmodconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout c61b1607ed4fbbf2ba7c86f29768cff44a1a88f8
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
arch/arm/crypto/aes-ce-core.S: Assembler messages:
>> arch/arm/crypto/aes-ce-core.S:467: Error: selected processor does not support `movw ip,:lower16:.Lcts_permute_table' in ARM mode
>> arch/arm/crypto/aes-ce-core.S:468: Error: selected processor does not support `movt ip,:upper16:.Lcts_permute_table' in ARM mode
arch/arm/crypto/aes-ce-core.S:553: Error: selected processor does not support `movw ip,:lower16:.Lcts_permute_table' in ARM mode
arch/arm/crypto/aes-ce-core.S:554: Error: selected processor does not support `movt ip,:upper16:.Lcts_permute_table' in ARM mode
vim +467 arch/arm/crypto/aes-ce-core.S
403
404 ENTRY(ce_aes_xts_encrypt)
405 push {r4-r6, lr}
406
407 bl ce_aes_xts_init @ run shared prologue
408 prepare_key r2, r3
409 vmov q4, q0
410
411 teq r6, #0 @ start of a block?
412 bne .Lxtsenc4x
413
414 .Lxtsencloop4x:
415 next_tweak q4, q4, q15, q10
416 .Lxtsenc4x:
417 subs r4, r4, #64
418 bmi .Lxtsenc1x
419 vld1.8 {q0-q1}, [r1]! @ get 4 pt blocks
420 vld1.8 {q2-q3}, [r1]!
421 next_tweak q5, q4, q15, q10
422 veor q0, q0, q4
423 next_tweak q6, q5, q15, q10
424 veor q1, q1, q5
425 next_tweak q7, q6, q15, q10
426 veor q2, q2, q6
427 veor q3, q3, q7
428 bl aes_encrypt_4x
429 veor q0, q0, q4
430 veor q1, q1, q5
431 veor q2, q2, q6
432 veor q3, q3, q7
433 vst1.8 {q0-q1}, [r0]! @ write 4 ct blocks
434 vst1.8 {q2-q3}, [r0]!
435 vmov q4, q7
436 teq r4, #0
437 beq .Lxtsencret
438 b .Lxtsencloop4x
439 .Lxtsenc1x:
440 adds r4, r4, #64
441 beq .Lxtsencout
442 subs r4, r4, #16
443 bmi .LxtsencctsNx
444 .Lxtsencloop:
445 vld1.8 {q0}, [r1]!
446 .Lxtsencctsout:
447 veor q0, q0, q4
448 bl aes_encrypt
449 veor q0, q0, q4
450 teq r4, #0
451 beq .Lxtsencout
452 subs r4, r4, #16
453 next_tweak q4, q4, q15, q6
454 bmi .Lxtsenccts
455 vst1.8 {q0}, [r0]!
456 b .Lxtsencloop
457 .Lxtsencout:
458 vst1.8 {q0}, [r0]
459 .Lxtsencret:
460 vst1.8 {q4}, [r5]
461 pop {r4-r6, pc}
462
463 .LxtsencctsNx:
464 vmov q0, q3
465 sub r0, r0, #16
466 .Lxtsenccts:
> 467 movw ip, :lower16:.Lcts_permute_table
> 468 movt ip, :upper16:.Lcts_permute_table
469
470 add r1, r1, r4 @ rewind input pointer
471 add r4, r4, #16 @ # bytes in final block
472 add lr, ip, #32
473 add ip, ip, r4
474 sub lr, lr, r4
475 add r4, r0, r4 @ output address of final block
476
477 vld1.8 {q1}, [r1] @ load final partial block
478 vld1.8 {q2}, [ip]
479 vld1.8 {q3}, [lr]
480
481 vtbl.8 d4, {d0-d1}, d4
482 vtbl.8 d5, {d0-d1}, d5
483 vtbx.8 d0, {d2-d3}, d6
484 vtbx.8 d1, {d2-d3}, d7
485
486 vst1.8 {q2}, [r4] @ overlapping stores
487 mov r4, #0
488 b .Lxtsencctsout
489 ENDPROC(ce_aes_xts_encrypt)
490
491
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
[yhuang:random-r0.1i 30/45] page_alloc.c:undefined reference to `node_random_demote_select_work'
by kbuild test robot
tree: yhuang/random-r0.1i
head: b7aa3b8f1aab2a4cae7429eca7ad6246975f4996
commit: 321be1f29c4be3e5407b5463bcb053990c65cfda [30/45] mm: Identify cold pages via randomly sampling + idle page tracking
config: sparc64-defconfig (attached as .config)
compiler: sparc64-linux-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 321be1f29c4be3e5407b5463bcb053990c65cfda
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=sparc64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
Note: the yhuang/random-r0.1i HEAD b7aa3b8f1aab2a4cae7429eca7ad6246975f4996 builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
mm/page_alloc.o: In function `free_area_init_node':
page_alloc.c:(.init.text+0xa6c): undefined reference to `node_random_promote_select_work'
page_alloc.c:(.init.text+0xa70): undefined reference to `node_random_promote_select_work'
page_alloc.c:(.init.text+0xac8): undefined reference to `node_random_promote_check_work'
page_alloc.c:(.init.text+0xacc): undefined reference to `node_random_promote_check_work'
>> page_alloc.c:(.init.text+0xb24): undefined reference to `node_random_demote_select_work'
page_alloc.c:(.init.text+0xb28): undefined reference to `node_random_demote_select_work'
>> page_alloc.c:(.init.text+0xb80): undefined reference to `node_random_demote_check_work'
page_alloc.c:(.init.text+0xb84): undefined reference to `node_random_demote_check_work'
mm/migrate.o: In function `move_to_new_page':
migrate.c:(.text+0x1454): undefined reference to `inc_hmem_state'
drivers/base/node.o: In function `random_migrate_period_ms_store':
node.c:(.text+0x144): undefined reference to `node_random_migrate_stop'
node.c:(.text+0x154): undefined reference to `node_random_migrate_start'
drivers/base/node.o: In function `random_migrate_mb_store':
node.c:(.text+0x2bc): undefined reference to `node_random_migrate_pages'
node.c:(.text+0x328): undefined reference to `node_random_migrate_stop'
node.c:(.text+0x340): undefined reference to `node_random_migrate_start'
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: error: storage size of 'pip_sft_rst' isn't known
by kbuild test robot
Hi Matthew,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 97f9a3c4eee55b0178b518ae7114a6a53372913d
commit: 171a9bae68c72f2d1260c3825203760856e6793b staging/octeon: Allow test build on !MIPS
date: 9 weeks ago
config: mips-allmodconfig (attached as .config)
compiler: mips-linux-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 171a9bae68c72f2d1260c3825203760856e6793b
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=mips
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from arch/mips/include/asm/octeon/octeon.h:11:0,
from drivers/staging/octeon/octeon-ethernet.h:19,
from drivers/staging/octeon/ethernet.c:22:
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_writeq_csr':
arch/mips/include/asm/octeon/cvmx.h:282:17: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
cvmx_write_csr((__force uint64_t)csr_addr, val);
^
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_readq_csr':
arch/mips/include/asm/octeon/cvmx.h:299:23: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
return cvmx_read_csr((__force uint64_t) csr_addr);
^
In file included from drivers/staging/octeon/octeon-ethernet.h:27:0,
from drivers/staging/octeon/ethernet.c:22:
arch/mips/include/asm/octeon/cvmx-ipd.h: In function 'cvmx_ipd_free_ptr':
>> arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: error: storage size of 'pip_sft_rst' isn't known
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
>> arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: error: 'CVMX_PIP_SFT_RST' undeclared (first use in this function); did you mean 'CVMX_CIU_SOFT_RST'?
pip_sft_rst.u64 = cvmx_read_csr(CVMX_PIP_SFT_RST);
^~~~~~~~~~~~~~~~
CVMX_CIU_SOFT_RST
arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: note: each undeclared identifier is reported only once for each function it appears in
arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: warning: unused variable 'pip_sft_rst' [-Wunused-variable]
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
--
In file included from arch/mips/include/asm/octeon/octeon.h:11:0,
from drivers/staging/octeon/octeon-ethernet.h:19,
from drivers/staging/octeon/ethernet-rx.c:26:
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_writeq_csr':
arch/mips/include/asm/octeon/cvmx.h:282:17: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
cvmx_write_csr((__force uint64_t)csr_addr, val);
^
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_readq_csr':
arch/mips/include/asm/octeon/cvmx.h:299:23: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
return cvmx_read_csr((__force uint64_t) csr_addr);
^
In file included from drivers/staging/octeon/octeon-ethernet.h:27:0,
from drivers/staging/octeon/ethernet-rx.c:26:
arch/mips/include/asm/octeon/cvmx-ipd.h: In function 'cvmx_ipd_free_ptr':
>> arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: error: storage size of 'pip_sft_rst' isn't known
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
>> arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: error: 'CVMX_PIP_SFT_RST' undeclared (first use in this function); did you mean 'CVMX_CIU_SOFT_RST'?
pip_sft_rst.u64 = cvmx_read_csr(CVMX_PIP_SFT_RST);
^~~~~~~~~~~~~~~~
CVMX_CIU_SOFT_RST
arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: note: each undeclared identifier is reported only once for each function it appears in
arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: warning: unused variable 'pip_sft_rst' [-Wunused-variable]
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
In file included from drivers/staging/octeon/ethernet-rx.c:27:0:
drivers/staging/octeon/ethernet-rx.c: In function 'cvm_oct_poll':
>> drivers/staging/octeon/ethernet-defines.h:30:38: error: 'CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE' undeclared (first use in this function); did you mean 'CONFIG_MDIO_OCTEON_MODULE'?
#define USE_ASYNC_IOBDMA (CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE > 0)
^
drivers/staging/octeon/ethernet-rx.c:190:6: note: in expansion of macro 'USE_ASYNC_IOBDMA'
if (USE_ASYNC_IOBDMA) {
^~~~~~~~~~~~~~~~
drivers/staging/octeon/ethernet-rx.c: In function 'cvm_oct_rx_initialize':
>> drivers/staging/octeon/ethernet-rx.c:472:25: error: 'OCTEON_IRQ_WORKQ0' undeclared (first use in this function); did you mean 'OCTEON_IS_MODEL'?
oct_rx_group[i].irq = OCTEON_IRQ_WORKQ0 + i;
^~~~~~~~~~~~~~~~~
OCTEON_IS_MODEL
--
In file included from arch/mips/include/asm/octeon/octeon.h:11:0,
from drivers/staging/octeon/octeon-ethernet.h:19,
from drivers/staging/octeon/ethernet-spi.c:13:
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_writeq_csr':
arch/mips/include/asm/octeon/cvmx.h:282:17: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
cvmx_write_csr((__force uint64_t)csr_addr, val);
^
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_readq_csr':
arch/mips/include/asm/octeon/cvmx.h:299:23: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
return cvmx_read_csr((__force uint64_t) csr_addr);
^
In file included from drivers/staging/octeon/octeon-ethernet.h:27:0,
from drivers/staging/octeon/ethernet-spi.c:13:
arch/mips/include/asm/octeon/cvmx-ipd.h: In function 'cvmx_ipd_free_ptr':
>> arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: error: storage size of 'pip_sft_rst' isn't known
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
>> arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: error: 'CVMX_PIP_SFT_RST' undeclared (first use in this function); did you mean 'CVMX_CIU_SOFT_RST'?
pip_sft_rst.u64 = cvmx_read_csr(CVMX_PIP_SFT_RST);
^~~~~~~~~~~~~~~~
CVMX_CIU_SOFT_RST
arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: note: each undeclared identifier is reported only once for each function it appears in
arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: warning: unused variable 'pip_sft_rst' [-Wunused-variable]
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
drivers/staging/octeon/ethernet-spi.c: In function 'cvm_oct_spi_init':
>> drivers/staging/octeon/ethernet-spi.c:198:19: error: 'OCTEON_IRQ_RML' undeclared (first use in this function); did you mean 'OCTEON_IS_MODEL'?
r = request_irq(OCTEON_IRQ_RML, cvm_oct_spi_rml_interrupt,
^~~~~~~~~~~~~~
OCTEON_IS_MODEL
drivers/staging/octeon/ethernet-spi.c: In function 'cvm_oct_spi_uninit':
drivers/staging/octeon/ethernet-spi.c:224:12: error: 'OCTEON_IRQ_RML' undeclared (first use in this function); did you mean 'OCTEON_IS_MODEL'?
free_irq(OCTEON_IRQ_RML, &number_spi_ports);
^~~~~~~~~~~~~~
OCTEON_IS_MODEL
--
In file included from arch/mips/include/asm/octeon/octeon.h:11:0,
from drivers/staging/octeon/octeon-ethernet.h:19,
from drivers/staging/octeon/ethernet-tx.c:25:
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_writeq_csr':
arch/mips/include/asm/octeon/cvmx.h:282:17: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
cvmx_write_csr((__force uint64_t)csr_addr, val);
^
arch/mips/include/asm/octeon/cvmx.h: In function 'cvmx_readq_csr':
arch/mips/include/asm/octeon/cvmx.h:299:23: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
return cvmx_read_csr((__force uint64_t) csr_addr);
^
In file included from drivers/staging/octeon/octeon-ethernet.h:27:0,
from drivers/staging/octeon/ethernet-tx.c:25:
arch/mips/include/asm/octeon/cvmx-ipd.h: In function 'cvmx_ipd_free_ptr':
>> arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: error: storage size of 'pip_sft_rst' isn't known
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
>> arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: error: 'CVMX_PIP_SFT_RST' undeclared (first use in this function); did you mean 'CVMX_CIU_SOFT_RST'?
pip_sft_rst.u64 = cvmx_read_csr(CVMX_PIP_SFT_RST);
^~~~~~~~~~~~~~~~
CVMX_CIU_SOFT_RST
arch/mips/include/asm/octeon/cvmx-ipd.h:331:36: note: each undeclared identifier is reported only once for each function it appears in
arch/mips/include/asm/octeon/cvmx-ipd.h:330:27: warning: unused variable 'pip_sft_rst' [-Wunused-variable]
union cvmx_pip_sft_rst pip_sft_rst;
^~~~~~~~~~~
In file included from drivers/staging/octeon/ethernet-tx.c:26:0:
drivers/staging/octeon/ethernet-tx.c: In function 'cvm_oct_xmit':
>> drivers/staging/octeon/ethernet-defines.h:30:38: error: 'CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE' undeclared (first use in this function); did you mean 'CONFIG_MDIO_OCTEON_MODULE'?
#define USE_ASYNC_IOBDMA (CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE > 0)
^
drivers/staging/octeon/ethernet-tx.c:169:6: note: in expansion of macro 'USE_ASYNC_IOBDMA'
if (USE_ASYNC_IOBDMA) {
^~~~~~~~~~~~~~~~
In file included from arch/mips/include/asm/barrier.h:11:0,
from include/linux/compiler.h:256,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/module.h:9,
from drivers/staging/octeon/ethernet-tx.c:8:
drivers/staging/octeon/ethernet-tx.c:264:37: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
hw_buffer.s.addr = XKPHYS_TO_PHYS((u64)skb->data);
^
arch/mips/include/asm/addrspace.h:128:30: note: in definition of macro 'XKPHYS_TO_PHYS'
#define XKPHYS_TO_PHYS(p) ((p) & TO_PHYS_MASK)
^
drivers/staging/octeon/ethernet-tx.c:268:37: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
hw_buffer.s.addr = XKPHYS_TO_PHYS((u64)skb->data);
^
arch/mips/include/asm/addrspace.h:128:30: note: in definition of macro 'XKPHYS_TO_PHYS'
#define XKPHYS_TO_PHYS(p) ((p) & TO_PHYS_MASK)
^
drivers/staging/octeon/ethernet-tx.c:276:20: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
XKPHYS_TO_PHYS((u64)skb_frag_address(fs));
^
arch/mips/include/asm/addrspace.h:128:30: note: in definition of macro 'XKPHYS_TO_PHYS'
#define XKPHYS_TO_PHYS(p) ((p) & TO_PHYS_MASK)
^
drivers/staging/octeon/ethernet-tx.c:280:37: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
hw_buffer.s.addr = XKPHYS_TO_PHYS((u64)CVM_OCT_SKB_CB(skb));
^
arch/mips/include/asm/addrspace.h:128:30: note: in definition of macro 'XKPHYS_TO_PHYS'
#define XKPHYS_TO_PHYS(p) ((p) & TO_PHYS_MASK)
^
drivers/staging/octeon/ethernet-tx.c: In function 'cvm_oct_tx_initialize':
>> drivers/staging/octeon/ethernet-tx.c:706:18: error: 'OCTEON_IRQ_TIMER1' undeclared (first use in this function); did you mean 'OCTEON_IS_MODEL'?
i = request_irq(OCTEON_IRQ_TIMER1,
^~~~~~~~~~~~~~~~~
OCTEON_IS_MODEL
drivers/staging/octeon/ethernet-tx.c: In function 'cvm_oct_tx_shutdown':
drivers/staging/octeon/ethernet-tx.c:717:11: error: 'OCTEON_IRQ_TIMER1' undeclared (first use in this function); did you mean 'OCTEON_IS_MODEL'?
free_irq(OCTEON_IRQ_TIMER1, cvm_oct_device);
^~~~~~~~~~~~~~~~~
OCTEON_IS_MODEL
vim +330 arch/mips/include/asm/octeon/cvmx-ipd.h
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 154
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 155 /**
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 156 * Supportive function for cvmx_fpa_shutdown_pool.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 157 */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 158 static inline void cvmx_ipd_free_ptr(void)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 159 {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 160 /* Only CN38XXp{1,2} cannot read pointer out of the IPD */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 161 if (!OCTEON_IS_MODEL(OCTEON_CN38XX_PASS1)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 162 && !OCTEON_IS_MODEL(OCTEON_CN38XX_PASS2)) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 163 int no_wptr = 0;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 164 union cvmx_ipd_ptr_count ipd_ptr_count;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 165 ipd_ptr_count.u64 = cvmx_read_csr(CVMX_IPD_PTR_COUNT);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 166
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 167 /* Handle Work Queue Entry in cn56xx and cn52xx */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 168 if (octeon_has_feature(OCTEON_FEATURE_NO_WPTR)) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 169 union cvmx_ipd_ctl_status ipd_ctl_status;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 170 ipd_ctl_status.u64 = cvmx_read_csr(CVMX_IPD_CTL_STATUS);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 171 if (ipd_ctl_status.s.no_wptr)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 172 no_wptr = 1;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 173 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 174
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 175 /* Free the prefetched WQE */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 176 if (ipd_ptr_count.s.wqev_cnt) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 177 union cvmx_ipd_wqe_ptr_valid ipd_wqe_ptr_valid;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 178 ipd_wqe_ptr_valid.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 179 cvmx_read_csr(CVMX_IPD_WQE_PTR_VALID);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 180 if (no_wptr)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 181 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 182 ((uint64_t) ipd_wqe_ptr_valid.s.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 183 ptr << 7), CVMX_FPA_PACKET_POOL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 184 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 185 else
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 186 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 187 ((uint64_t) ipd_wqe_ptr_valid.s.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 188 ptr << 7), CVMX_FPA_WQE_POOL, 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 189 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 190
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 191 /* Free all WQE in the fifo */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 192 if (ipd_ptr_count.s.wqe_pcnt) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 193 int i;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 194 union cvmx_ipd_pwp_ptr_fifo_ctl ipd_pwp_ptr_fifo_ctl;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 195 ipd_pwp_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 196 cvmx_read_csr(CVMX_IPD_PWP_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 197 for (i = 0; i < ipd_ptr_count.s.wqe_pcnt; i++) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 198 ipd_pwp_ptr_fifo_ctl.s.cena = 0;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 199 ipd_pwp_ptr_fifo_ctl.s.raddr =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 200 ipd_pwp_ptr_fifo_ctl.s.max_cnts +
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 201 (ipd_pwp_ptr_fifo_ctl.s.wraddr +
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 202 i) % ipd_pwp_ptr_fifo_ctl.s.max_cnts;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 203 cvmx_write_csr(CVMX_IPD_PWP_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 204 ipd_pwp_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 205 ipd_pwp_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 206 cvmx_read_csr(CVMX_IPD_PWP_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 207 if (no_wptr)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 208 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 209 ((uint64_t)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 210 ipd_pwp_ptr_fifo_ctl.s.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 211 ptr << 7),
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 212 CVMX_FPA_PACKET_POOL, 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 213 else
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 214 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 215 ((uint64_t)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 216 ipd_pwp_ptr_fifo_ctl.s.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 217 ptr << 7),
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 218 CVMX_FPA_WQE_POOL, 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 219 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 220 ipd_pwp_ptr_fifo_ctl.s.cena = 1;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 221 cvmx_write_csr(CVMX_IPD_PWP_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 222 ipd_pwp_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 223 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 224
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 225 /* Free the prefetched packet */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 226 if (ipd_ptr_count.s.pktv_cnt) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 227 union cvmx_ipd_pkt_ptr_valid ipd_pkt_ptr_valid;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 228 ipd_pkt_ptr_valid.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 229 cvmx_read_csr(CVMX_IPD_PKT_PTR_VALID);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 230 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 231 (ipd_pkt_ptr_valid.s.ptr << 7),
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 232 CVMX_FPA_PACKET_POOL, 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 233 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 234
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 235 /* Free the per port prefetched packets */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 236 if (1) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 237 int i;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 238 union cvmx_ipd_prc_port_ptr_fifo_ctl
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 239 ipd_prc_port_ptr_fifo_ctl;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 240 ipd_prc_port_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 241 cvmx_read_csr(CVMX_IPD_PRC_PORT_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 242
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 243 for (i = 0; i < ipd_prc_port_ptr_fifo_ctl.s.max_pkt;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 244 i++) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 245 ipd_prc_port_ptr_fifo_ctl.s.cena = 0;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 246 ipd_prc_port_ptr_fifo_ctl.s.raddr =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 247 i % ipd_prc_port_ptr_fifo_ctl.s.max_pkt;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 248 cvmx_write_csr(CVMX_IPD_PRC_PORT_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 249 ipd_prc_port_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 250 ipd_prc_port_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 251 cvmx_read_csr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 252 (CVMX_IPD_PRC_PORT_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 253 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 254 ((uint64_t)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 255 ipd_prc_port_ptr_fifo_ctl.s.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 256 ptr << 7), CVMX_FPA_PACKET_POOL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 257 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 258 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 259 ipd_prc_port_ptr_fifo_ctl.s.cena = 1;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 260 cvmx_write_csr(CVMX_IPD_PRC_PORT_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 261 ipd_prc_port_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 262 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 263
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 264 /* Free all packets in the holding fifo */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 265 if (ipd_ptr_count.s.pfif_cnt) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 266 int i;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 267 union cvmx_ipd_prc_hold_ptr_fifo_ctl
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 268 ipd_prc_hold_ptr_fifo_ctl;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 269
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 270 ipd_prc_hold_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 271 cvmx_read_csr(CVMX_IPD_PRC_HOLD_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 272
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 273 for (i = 0; i < ipd_ptr_count.s.pfif_cnt; i++) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 274 ipd_prc_hold_ptr_fifo_ctl.s.cena = 0;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 275 ipd_prc_hold_ptr_fifo_ctl.s.raddr =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 276 (ipd_prc_hold_ptr_fifo_ctl.s.praddr +
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 277 i) % ipd_prc_hold_ptr_fifo_ctl.s.max_pkt;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 278 cvmx_write_csr(CVMX_IPD_PRC_HOLD_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 279 ipd_prc_hold_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 280 ipd_prc_hold_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 281 cvmx_read_csr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 282 (CVMX_IPD_PRC_HOLD_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 283 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 284 ((uint64_t)
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 285 ipd_prc_hold_ptr_fifo_ctl.s.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 286 ptr << 7), CVMX_FPA_PACKET_POOL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 287 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 288 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 289 ipd_prc_hold_ptr_fifo_ctl.s.cena = 1;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 290 cvmx_write_csr(CVMX_IPD_PRC_HOLD_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 291 ipd_prc_hold_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 292 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 293
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 294 /* Free all packets in the fifo */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 295 if (ipd_ptr_count.s.pkt_pcnt) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 296 int i;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 297 union cvmx_ipd_pwp_ptr_fifo_ctl ipd_pwp_ptr_fifo_ctl;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 298 ipd_pwp_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 299 cvmx_read_csr(CVMX_IPD_PWP_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 300
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 301 for (i = 0; i < ipd_ptr_count.s.pkt_pcnt; i++) {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 302 ipd_pwp_ptr_fifo_ctl.s.cena = 0;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 303 ipd_pwp_ptr_fifo_ctl.s.raddr =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 304 (ipd_pwp_ptr_fifo_ctl.s.praddr +
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 305 i) % ipd_pwp_ptr_fifo_ctl.s.max_cnts;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 306 cvmx_write_csr(CVMX_IPD_PWP_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 307 ipd_pwp_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 308 ipd_pwp_ptr_fifo_ctl.u64 =
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 309 cvmx_read_csr(CVMX_IPD_PWP_PTR_FIFO_CTL);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 310 cvmx_fpa_free(cvmx_phys_to_ptr
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 311 ((uint64_t) ipd_pwp_ptr_fifo_ctl.
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 312 s.ptr << 7),
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 313 CVMX_FPA_PACKET_POOL, 0);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 314 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 315 ipd_pwp_ptr_fifo_ctl.s.cena = 1;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 316 cvmx_write_csr(CVMX_IPD_PWP_PTR_FIFO_CTL,
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 317 ipd_pwp_ptr_fifo_ctl.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 318 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 319
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 320 /* Reset the IPD to get all buffers out of it */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 321 {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 322 union cvmx_ipd_ctl_status ipd_ctl_status;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 323 ipd_ctl_status.u64 = cvmx_read_csr(CVMX_IPD_CTL_STATUS);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 324 ipd_ctl_status.s.reset = 1;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 325 cvmx_write_csr(CVMX_IPD_CTL_STATUS, ipd_ctl_status.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 326 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 327
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 328 /* Reset the PIP */
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 329 {
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 @330 union cvmx_pip_sft_rst pip_sft_rst;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 @331 pip_sft_rst.u64 = cvmx_read_csr(CVMX_PIP_SFT_RST);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 332 pip_sft_rst.s.rst = 1;
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 333 cvmx_write_csr(CVMX_PIP_SFT_RST, pip_sft_rst.u64);
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 334 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 335 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 336 }
80ff0fd3ab6451 drivers/staging/octeon/cvmx-ipd.h David Daney 2009-05-05 337
:::::: The code at line 330 was first introduced by commit
:::::: 80ff0fd3ab6451407a20c19b80c1643c4a6d6434 Staging: Add octeon-ethernet driver files.
:::::: TO: David Daney <ddaney(a)caviumnetworks.com>
:::::: CC: Ralf Baechle <ralf(a)linux-mips.org>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
[omap-audio:peter/ti-linux-4.19.y/wip 7351/9541] platform.c:undefined reference to `devm_ioremap_resource'
by kbuild test robot
Hi Bartosz,
FYI, the error/warning still remains.
tree: https://github.com/omap-audio/linux-audio peter/ti-linux-4.19.y/wip
head: 43b20466ec6976ba9f08c94c68b2d74ac5ef838d
commit: 7a3c8cd45fa7fe4cfd6ed766f4fc8530fa006c4d [7351/9541] drivers: provide devm_platform_ioremap_resource()
config: um-x86_64_defconfig (attached as .config)
compiler: gcc-7 (Debian 7.4.0-13) 7.4.0
reproduce:
git checkout 7a3c8cd45fa7fe4cfd6ed766f4fc8530fa006c4d
# save the attached .config to linux build tree
make ARCH=um SUBARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
/usr/bin/ld: drivers/base/platform.o: in function `devm_platform_ioremap_resource':
>> platform.c:(.text+0x109): undefined reference to `devm_ioremap_resource'
collect2: error: ld returned 1 exit status
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
[yhuang:random-r0.1i 27/45] mm/page_idle.c:300:6: error: redefinition of 'node_random_promote_work'
by kbuild test robot
tree: yhuang/random-r0.1i
head: b7aa3b8f1aab2a4cae7429eca7ad6246975f4996
commit: 16178d86a313a3cc31ea2b5aaaeb2f6230a4fdc0 [27/45] mm: Support to promote to fast memory node randomly and periodically
config: mips-allmodconfig (attached as .config)
compiler: mips-linux-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 16178d86a313a3cc31ea2b5aaaeb2f6230a4fdc0
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=mips
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
mm/page_idle.c:258:6: error: redefinition of 'node_random_migrate_pages'
void node_random_migrate_pages(struct pglist_data *pgdat,
^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from mm/page_idle.c:14:0:
include/linux/node.h:207:20: note: previous definition of 'node_random_migrate_pages' was here
static inline void node_random_migrate_pages(struct pglist_data *pgdat,
^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/page_idle.c:300:6: error: redefinition of 'node_random_promote_work'
void node_random_promote_work(struct work_struct *work)
^~~~~~~~~~~~~~~~~~~~~~~~
In file included from mm/page_idle.c:14:0:
include/linux/node.h:210:20: note: previous definition of 'node_random_promote_work' was here
static inline void node_random_promote_work(struct work_struct *work) {}
^~~~~~~~~~~~~~~~~~~~~~~~
mm/page_idle.c:312:6: error: redefinition of 'node_random_promote_start'
void node_random_promote_start(struct pglist_data *pgdat)
^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from mm/page_idle.c:14:0:
include/linux/node.h:212:20: note: previous definition of 'node_random_promote_start' was here
static inline void node_random_promote_start(struct pglist_data *pgdat) {}
^~~~~~~~~~~~~~~~~~~~~~~~~
mm/page_idle.c:319:6: error: redefinition of 'node_random_promote_stop'
void node_random_promote_stop(struct pglist_data *pgdat)
^~~~~~~~~~~~~~~~~~~~~~~~
In file included from mm/page_idle.c:14:0:
include/linux/node.h:214:20: note: previous definition of 'node_random_promote_stop' was here
static inline void node_random_promote_stop(struct pglist_data *pgdat) {}
^~~~~~~~~~~~~~~~~~~~~~~~
vim +/node_random_promote_work +300 mm/page_idle.c
257
> 258 void node_random_migrate_pages(struct pglist_data *pgdat,
259 int nr_page, int target_nid)
260 {
261 int i, nr = 0;
262 unsigned long pfn = 0;
263 struct page *page;
264
265 migrate_prep();
266
267 /* Stop when found target number of pages or tried enough times */
268 for (i = 0; i < nr_page * 8 && nr < nr_page; i++) {
269 prandom_bytes(&pfn, sizeof(pfn));
270 pfn %= pgdat->node_spanned_pages;
271 pfn += pgdat->node_start_pfn;
272 if (!pfn_valid(pfn))
273 continue;
274 page = pfn_to_page(pfn);
275 /* TODO: support huge page and THP */
276 if (PageTransCompound(page) || !PageLRU(page) ||
277 PageHuge(page))
278 continue;
279 /* Nodes PFN range may overlap */
280 if (page_pgdat(page) != pgdat)
281 continue;
282 if (!get_page_unless_zero(page))
283 continue;
284 /*
285 * get_page_unless_zero() is fully ordered, just
286 * prevent compiler from reordering.
287 */
288 barrier();
289 if (PageTransCompound(page) || !PageLRU(page) ||
290 PageHuge(page)) {
291 put_page(page);
292 continue;
293 }
294
295 migrate_misplaced_page(page, NULL, target_nid);
296 nr++;
297 }
298 }
299
> 300 void node_random_promote_work(struct work_struct *work)
301 {
302 struct pglist_data *pgdat = container_of(to_delayed_work(work),
303 struct pglist_data,
304 random_promote_state.work);
305 int nid = next_promotion_node(pgdat->node_id);
306
307 node_random_migrate_pages(pgdat, pgdat->random_promote_state.nr_page,
308 nid);
309 node_random_promote_start(pgdat);
310 }
311
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
Re: [PATCH v6 1/1] memory_hotplug: Add a bounds check to __add_pages
by kbuild test robot
Hi Alastair,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on linus/master]
[cannot apply to v5.3 next-20190926]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
url: https://github.com/0day-ci/linux/commits/Alastair-D-Silva/Add-bounds-chec...
config: i386-randconfig-g004-201939 (attached as .config)
compiler: gcc-7 (Debian 7.4.0-13) 7.4.0
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
In file included from arch/x86/include/asm/bug.h:83:0,
from include/linux/bug.h:5,
from include/linux/mmdebug.h:5,
from include/linux/mm.h:9,
from mm/memory_hotplug.c:9:
mm/memory_hotplug.c: In function 'check_hotplug_memory_addressable':
>> mm/memory_hotplug.c:289:8: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 2 has type 'unsigned int' [-Wformat=]
"Hotplugged memory exceeds maximum addressable address, range=%#llx-%#llx, maximum=%#llx\n",
^
include/asm-generic/bug.h:92:17: note: in definition of macro '__WARN_printf'
__warn_printk(arg); \
^~~
mm/memory_hotplug.c:288:3: note: in expansion of macro 'WARN'
WARN(1,
^~~~
vim +289 mm/memory_hotplug.c
280
281 static int check_hotplug_memory_addressable(unsigned long pfn,
282 unsigned long nr_pages)
283 {
284 const u64 max_addr = PFN_PHYS(pfn + nr_pages) - 1;
285
286 if (max_addr >> MAX_PHYSMEM_BITS) {
287 const u64 max_allowed = (1ull << (MAX_PHYSMEM_BITS + 1)) - 1;
288 WARN(1,
> 289 "Hotplugged memory exceeds maximum addressable address, range=%#llx-%#llx, maximum=%#llx\n",
290 PFN_PHYS(pfn), max_addr, max_allowed);
291 return -E2BIG;
292 }
293
294 return 0;
295 }
296
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
[omap:droid4-pending-mdm-v5.3 1/16] include/linux/serdev-gsm.h:29:2: error: unknown type name 'atomic_t'
by kbuild test robot
Hi Tony,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap.git droid4-pending-mdm-v5.3
head: 201a74c13723a33b840263db6f0ee8e5e74933bd
commit: b0acc1316f8969c3f3463d549ce5031ce87c9b58 [1/16] tty: n_gsm: Add support for serdev drivers
config: x86_64-randconfig-s1-201939 (attached as .config)
compiler: gcc-5 (Ubuntu 5.5.0-12ubuntu1) 5.5.0 20171010
reproduce:
git checkout b0acc1316f8969c3f3463d549ce5031ce87c9b58
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from <command-line>:0:0:
>> include/linux/serdev-gsm.h:29:2: error: unknown type name 'atomic_t'
atomic_t asleep;
^
>> include/linux/serdev-gsm.h:37:40: error: unknown type name 'u8'
int (*output)(struct gsm_serdev *gsd, u8 *data, int len);
^
include/linux/serdev-gsm.h:39:14: error: unknown type name 'u8'
const u8 *buf, int len);
^
>> include/linux/serdev-gsm.h:52:7: error: unknown type name 'size_t'
size_t len);
^
include/linux/serdev-gsm.h:53:1: warning: no semicolon at end of struct or union
};
^
include/linux/serdev-gsm.h:60:51: warning: 'struct device' declared inside parameter list
static inline void *gsm_serdev_get_drvdata(struct device *dev)
^
include/linux/serdev-gsm.h:60:51: warning: its scope is only this definition or declaration, which is probably not what you want
include/linux/serdev-gsm.h: In function 'gsm_serdev_get_drvdata':
>> include/linux/serdev-gsm.h:62:33: error: implicit declaration of function 'to_serdev_device' [-Werror=implicit-function-declaration]
struct serdev_device *serdev = to_serdev_device(dev);
^
include/linux/serdev-gsm.h:62:33: warning: initialization makes pointer from integer without a cast [-Wint-conversion]
>> include/linux/serdev-gsm.h:63:27: error: implicit declaration of function 'serdev_device_get_drvdata' [-Werror=implicit-function-declaration]
struct gsm_serdev *gsd = serdev_device_get_drvdata(serdev);
^
include/linux/serdev-gsm.h:63:27: warning: initialization makes pointer from integer without a cast [-Wint-conversion]
>> include/linux/serdev-gsm.h:68:9: error: 'NULL' undeclared (first use in this function)
return NULL;
^
include/linux/serdev-gsm.h:68:9: note: each undeclared identifier is reported only once for each function it appears in
include/linux/serdev-gsm.h: At top level:
include/linux/serdev-gsm.h:71:50: warning: 'struct device' declared inside parameter list
static inline void gsm_serdev_set_drvdata(struct device *dev, void *drvdata)
^
include/linux/serdev-gsm.h: In function 'gsm_serdev_set_drvdata':
include/linux/serdev-gsm.h:73:33: warning: initialization makes pointer from integer without a cast [-Wint-conversion]
struct serdev_device *serdev = to_serdev_device(dev);
^
include/linux/serdev-gsm.h:74:27: warning: initialization makes pointer from integer without a cast [-Wint-conversion]
struct gsm_serdev *gsd = serdev_device_get_drvdata(serdev);
^
include/linux/serdev-gsm.h: In function 'gsm_serdev_set_config':
>> include/linux/serdev-gsm.h:106:10: error: 'ENODEV' undeclared (first use in this function)
return -ENODEV;
^
include/linux/serdev-gsm.h: In function 'gsm_serdev_register_dlci':
include/linux/serdev-gsm.h:121:10: error: 'ENODEV' undeclared (first use in this function)
return -ENODEV;
^
include/linux/serdev-gsm.h: At top level:
include/linux/serdev-gsm.h:146:14: error: unknown type name 'u8'
const u8 *buf, int len)
^
include/linux/serdev-gsm.h: In function 'gsm_serdev_write':
include/linux/serdev-gsm.h:151:10: error: 'ENODEV' undeclared (first use in this function)
return -ENODEV;
^
cc1: some warnings being treated as errors
vim +/atomic_t +29 include/linux/serdev-gsm.h
8
9 /**
10 * struct gsm_serdev - serdev-gsm instance
11 * @serdev: serdev instance
12 * @gsm: ts 27.010 n_gsm instance
13 * @asleep: device is in idle state
14 * @drvdata: serdev-gsm consumer driver data
15 * @get_config: get ts 27.010 config
16 * @set_config: set ts 27.010 config
17 * @register_dlci: register ts 27.010 channel
18 * @unregister_dlci: unregister ts 27.010 channel
19 * @output: read data from ts 27.010 channel
20 * @write: write data to a ts 27.010 channel
21 * @kick: indicate more data is ready
22 *
23 * Currently only serdev and output must be initialized, the rest are
24 * are initialized by gsm_serdev_register_dlci().
25 */
26 struct gsm_serdev {
27 struct serdev_device *serdev;
28 struct gsm_mux *gsm;
> 29 atomic_t asleep;
30 void *drvdata;
31 int (*get_config)(struct gsm_serdev *gsd, struct gsm_config *c);
32 int (*set_config)(struct gsm_serdev *gsd, struct gsm_config *c);
33 int (*register_dlci)(struct gsm_serdev *gsd,
34 struct gsm_serdev_dlci *ops);
35 void (*unregister_dlci)(struct gsm_serdev *gsd,
36 struct gsm_serdev_dlci *ops);
> 37 int (*output)(struct gsm_serdev *gsd, u8 *data, int len);
38 int (*write)(struct gsm_serdev *gsd, struct gsm_serdev_dlci *ops,
39 const u8 *buf, int len);
40 void (*kick)(struct gsm_serdev *gsd);
41 };
42
43 /**
44 * struct gsm_serdev_dlci - serdev-gsm ts 27.010 channel data
45 * @line: ts 27.010 channel, control channel 0 is not available
46 * @receive_buf: function to handle data received for the channel
47 */
48 struct gsm_serdev_dlci {
49 int line;
50 int (*receive_buf)(struct gsm_serdev_dlci *ops,
51 const unsigned char *buf,
> 52 size_t len);
> 53 };
54
55 #ifdef CONFIG_SERIAL_DEV_BUS
56
57 int gsm_serdev_register_device(struct gsm_serdev *gsd);
58 void gsm_serdev_unregister_device(struct gsm_serdev *gsd);
59
> 60 static inline void *gsm_serdev_get_drvdata(struct device *dev)
61 {
> 62 struct serdev_device *serdev = to_serdev_device(dev);
> 63 struct gsm_serdev *gsd = serdev_device_get_drvdata(serdev);
64
65 if (gsd)
66 return gsd->drvdata;
67
> 68 return NULL;
69 }
70
71 static inline void gsm_serdev_set_drvdata(struct device *dev, void *drvdata)
72 {
> 73 struct serdev_device *serdev = to_serdev_device(dev);
74 struct gsm_serdev *gsd = serdev_device_get_drvdata(serdev);
75
76 if (gsd)
77 gsd->drvdata = drvdata;
78 }
79
80 /**
81 * gsm_serdev_get_config - read ts 27.010 config
82 * @gsd: serdev-gsm instance
83 * @c: ts 27.010 config data
84 *
85 * See gsm_copy_config_values() for more information.
86 */
87 static inline
88 int gsm_serdev_get_config(struct gsm_serdev *gsd, struct gsm_config *c)
89 {
90 return gsd->get_config(gsd, c);
91 }
92
93 /**
94 * gsm_serdev_set_config - set ts 27.010 config
95 * @gsd: serdev-gsm instance
96 * @c: ts 27.010 config data
97 *
98 * See gsm_config() for more information.
99 */
100 static inline
101 int gsm_serdev_set_config(struct gsm_serdev *gsd, struct gsm_config *c)
102 {
103 if (gsd && gsd->set_config)
104 return gsd->set_config(gsd, c);
105
> 106 return -ENODEV;
107 }
108
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
[yhuang:random-r0.1i 24/42] mm/page_idle.c:243:6: error: redefinition of 'node_random_migrate_pages'
by kbuild test robot
tree: yhuang/random-r0.1i
head: 96efac420c3a75d62cf4ff43184d4dbd0ce94b55
commit: 450f0596b411479636718fbeb5eb458d543daeba [24/42] mm: Support to promote pages to fast memory node randomly
config: mips-allmodconfig (attached as .config)
compiler: mips-linux-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 450f0596b411479636718fbeb5eb458d543daeba
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=mips
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> mm/page_idle.c:243:6: error: redefinition of 'node_random_migrate_pages'
void node_random_migrate_pages(struct pglist_data *pgdat, int nr_page,
^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from mm/page_idle.c:14:0:
include/linux/node.h:204:20: note: previous definition of 'node_random_migrate_pages' was here
static inline void node_random_migrate_pages(struct pglist_data *pgdat,
^~~~~~~~~~~~~~~~~~~~~~~~~
vim +/node_random_migrate_pages +243 mm/page_idle.c
242
> 243 void node_random_migrate_pages(struct pglist_data *pgdat, int nr_page,
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
[yhuang:random-r0.1i 41/42] drivers/base/node.c:768: undefined reference to `node_random_migrate_start'
by kbuild test robot
tree: yhuang/random-r0.1i
head: 96efac420c3a75d62cf4ff43184d4dbd0ce94b55
commit: ddebbe29896aa7b2aa3f84ebeada1e3c466a37fa [41/42] 2 stage filter for promotion
config: x86_64-randconfig-e004-201939 (attached as .config)
compiler: gcc-7 (Debian 7.4.0-13) 7.4.0
reproduce:
git checkout ddebbe29896aa7b2aa3f84ebeada1e3c466a37fa
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
ld: mm/page_alloc.o: in function `pgdat_init_random_migrate':
mm/page_alloc.c:6632: undefined reference to `node_random_promote_work'
ld: mm/page_alloc.c:6634: undefined reference to `node_random_demote_work'
ld: drivers/base/node.o: in function `random_migrate_threshold_max_ms_store':
drivers/base/node.c:786: undefined reference to `node_random_migrate_stop'
ld: drivers/base/node.c:790: undefined reference to `node_random_migrate_start'
ld: drivers/base/node.o: in function `random_migrate_period_ms_store':
>> drivers/base/node.c:768: undefined reference to `node_random_migrate_start'
>> ld: drivers/base/node.c:759: undefined reference to `node_random_migrate_stop'
>> ld: drivers/base/node.c:759: undefined reference to `node_random_migrate_stop'
ld: drivers/base/node.o: in function `random_migrate_mb_store':
drivers/base/node.c:725: undefined reference to `node_random_migrate_stop'
ld: drivers/base/node.c:729: undefined reference to `node_random_migrate_pages'
ld: drivers/base/node.c:731: undefined reference to `node_random_migrate_start'
vim +768 drivers/base/node.c
450f0596b41147 Huang Ying 2019-09-11 736
321be1f29c4be3 Huang Ying 2019-09-13 737 static ssize_t random_migrate_period_ms_store(
321be1f29c4be3 Huang Ying 2019-09-13 738 struct pglist_data *pgdat, struct random_migrate_state *rm_state,
321be1f29c4be3 Huang Ying 2019-09-13 739 const char *buf, size_t count, bool promote)
16178d86a313a3 Huang Ying 2019-09-11 740 {
321be1f29c4be3 Huang Ying 2019-09-13 741 int err, tnid;
16178d86a313a3 Huang Ying 2019-09-11 742 long period, orig_period;
16178d86a313a3 Huang Ying 2019-09-11 743
16178d86a313a3 Huang Ying 2019-09-11 744 err = kstrtol(buf, 0, &period);
16178d86a313a3 Huang Ying 2019-09-11 745 if (err)
16178d86a313a3 Huang Ying 2019-09-11 746 return -EINVAL;
16178d86a313a3 Huang Ying 2019-09-11 747
16178d86a313a3 Huang Ying 2019-09-11 748 if (period < 0)
16178d86a313a3 Huang Ying 2019-09-11 749 return -EINVAL;
16178d86a313a3 Huang Ying 2019-09-11 750
321be1f29c4be3 Huang Ying 2019-09-13 751 if (promote)
321be1f29c4be3 Huang Ying 2019-09-13 752 tnid = next_promotion_node(pgdat->node_id);
321be1f29c4be3 Huang Ying 2019-09-13 753 else
321be1f29c4be3 Huang Ying 2019-09-13 754 tnid = next_migration_node(pgdat->node_id);
321be1f29c4be3 Huang Ying 2019-09-13 755 if (tnid == TERMINAL_NODE)
16178d86a313a3 Huang Ying 2019-09-11 756 return -EINVAL;
16178d86a313a3 Huang Ying 2019-09-11 757
16178d86a313a3 Huang Ying 2019-09-11 758 mutex_lock(&random_migrate_mutex);
907384318ec6a1 Huang Ying 2019-09-24 @759 node_random_migrate_stop(rm_state);
321be1f29c4be3 Huang Ying 2019-09-13 760 orig_period = rm_state->period;
77c411004cf0f7 Huang Ying 2019-09-12 761 period = msecs_to_jiffies(period);
321be1f29c4be3 Huang Ying 2019-09-13 762 rm_state->period = period;
ddebbe29896aa7 Huang Ying 2019-09-29 763 if (promote)
ddebbe29896aa7 Huang Ying 2019-09-29 764 rm_state->threshold = max(period / 2, 1L);
ddebbe29896aa7 Huang Ying 2019-09-29 765 else
321be1f29c4be3 Huang Ying 2019-09-13 766 rm_state->threshold = period;
907384318ec6a1 Huang Ying 2019-09-24 767 if (period && rm_state->nr_page)
321be1f29c4be3 Huang Ying 2019-09-13 @768 node_random_migrate_start(pgdat, rm_state);
16178d86a313a3 Huang Ying 2019-09-11 769 mutex_unlock(&random_migrate_mutex);
16178d86a313a3 Huang Ying 2019-09-11 770
16178d86a313a3 Huang Ying 2019-09-11 771 return count;
16178d86a313a3 Huang Ying 2019-09-11 772 }
16178d86a313a3 Huang Ying 2019-09-11 773
039975d2ffdf8c Huang Ying 2019-09-25 774 static ssize_t random_migrate_threshold_max_ms_store(
039975d2ffdf8c Huang Ying 2019-09-25 775 struct pglist_data *pgdat, struct random_migrate_state *rm_state,
039975d2ffdf8c Huang Ying 2019-09-25 776 const char *buf, size_t count)
039975d2ffdf8c Huang Ying 2019-09-25 777 {
039975d2ffdf8c Huang Ying 2019-09-25 778 int err;
039975d2ffdf8c Huang Ying 2019-09-25 779 long threshold_max;
039975d2ffdf8c Huang Ying 2019-09-25 780
039975d2ffdf8c Huang Ying 2019-09-25 781 err = kstrtol(buf, 0, &threshold_max);
039975d2ffdf8c Huang Ying 2019-09-25 782 if (err)
039975d2ffdf8c Huang Ying 2019-09-25 783 return -EINVAL;
039975d2ffdf8c Huang Ying 2019-09-25 784
039975d2ffdf8c Huang Ying 2019-09-25 785 mutex_lock(&random_migrate_mutex);
039975d2ffdf8c Huang Ying 2019-09-25 @786 node_random_migrate_stop(rm_state);
039975d2ffdf8c Huang Ying 2019-09-25 787 if (threshold_max < 0)
039975d2ffdf8c Huang Ying 2019-09-25 788 return -EINVAL;
039975d2ffdf8c Huang Ying 2019-09-25 789 if (rm_state->period && rm_state->nr_page)
039975d2ffdf8c Huang Ying 2019-09-25 790 node_random_migrate_start(pgdat, rm_state);
039975d2ffdf8c Huang Ying 2019-09-25 791 mutex_unlock(&random_migrate_mutex);
039975d2ffdf8c Huang Ying 2019-09-25 792
039975d2ffdf8c Huang Ying 2019-09-25 793 rm_state->threshold_max = msecs_to_jiffies(threshold_max);
039975d2ffdf8c Huang Ying 2019-09-25 794
039975d2ffdf8c Huang Ying 2019-09-25 795 return count;
039975d2ffdf8c Huang Ying 2019-09-25 796 }
039975d2ffdf8c Huang Ying 2019-09-25 797
:::::: The code at line 768 was first introduced by commit
:::::: 321be1f29c4be3e5407b5463bcb053990c65cfda mm: Identify cold pages via randomly sampling + idle page tracking
:::::: TO: Huang Ying <ying.huang(a)intel.com>
:::::: CC: Huang Ying <ying.huang(a)intel.com>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months
[linux-review:UPDATE-20190916-221311/Vandana-BN/vivid-Add-metadata-capture-support/20190903-185904 1/1] drivers/media//platform/vivid/vivid-core.c:1563:36: error: 'VFL_TYPE_METADATA' undeclared
by kbuild test robot
tree: https://github.com/0day-ci/linux/commits/UPDATE-20190916-221311/Vandana-B...
head: 2e16ebdb7e52eddc13c6a8e28d04075e5246e75c
commit: 2e16ebdb7e52eddc13c6a8e28d04075e5246e75c [1/1] vivid: Add metadata capture support
config: x86_64-randconfig-s2-201939 (attached as .config)
compiler: gcc-5 (Ubuntu 5.5.0-12ubuntu1) 5.5.0 20171010
reproduce:
git checkout 2e16ebdb7e52eddc13c6a8e28d04075e5246e75c
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/media//platform/vivid/vivid-core.c: In function 'vivid_create_instance':
>> drivers/media//platform/vivid/vivid-core.c:1563:36: error: 'VFL_TYPE_METADATA' undeclared (first use in this function)
ret = video_register_device(vfd, VFL_TYPE_METADATA,
^
drivers/media//platform/vivid/vivid-core.c:1563:36: note: each undeclared identifier is reported only once for each function it appears in
vim +/VFL_TYPE_METADATA +1563 drivers/media//platform/vivid/vivid-core.c
1497
1498 ret = video_register_device(vfd, VFL_TYPE_SDR, sdr_cap_nr[inst]);
1499 if (ret < 0)
1500 goto unreg_dev;
1501 v4l2_info(&dev->v4l2_dev, "V4L2 capture device registered as %s\n",
1502 video_device_node_name(vfd));
1503 }
1504
1505 if (dev->has_radio_rx) {
1506 vfd = &dev->radio_rx_dev;
1507 snprintf(vfd->name, sizeof(vfd->name),
1508 "vivid-%03d-rad-rx", inst);
1509 vfd->fops = &vivid_radio_fops;
1510 vfd->ioctl_ops = &vivid_ioctl_ops;
1511 vfd->device_caps = dev->radio_rx_caps;
1512 vfd->release = video_device_release_empty;
1513 vfd->v4l2_dev = &dev->v4l2_dev;
1514 vfd->lock = &dev->mutex;
1515 video_set_drvdata(vfd, dev);
1516
1517 ret = video_register_device(vfd, VFL_TYPE_RADIO, radio_rx_nr[inst]);
1518 if (ret < 0)
1519 goto unreg_dev;
1520 v4l2_info(&dev->v4l2_dev, "V4L2 receiver device registered as %s\n",
1521 video_device_node_name(vfd));
1522 }
1523
1524 if (dev->has_radio_tx) {
1525 vfd = &dev->radio_tx_dev;
1526 snprintf(vfd->name, sizeof(vfd->name),
1527 "vivid-%03d-rad-tx", inst);
1528 vfd->vfl_dir = VFL_DIR_TX;
1529 vfd->fops = &vivid_radio_fops;
1530 vfd->ioctl_ops = &vivid_ioctl_ops;
1531 vfd->device_caps = dev->radio_tx_caps;
1532 vfd->release = video_device_release_empty;
1533 vfd->v4l2_dev = &dev->v4l2_dev;
1534 vfd->lock = &dev->mutex;
1535 video_set_drvdata(vfd, dev);
1536
1537 ret = video_register_device(vfd, VFL_TYPE_RADIO, radio_tx_nr[inst]);
1538 if (ret < 0)
1539 goto unreg_dev;
1540 v4l2_info(&dev->v4l2_dev, "V4L2 transmitter device registered as %s\n",
1541 video_device_node_name(vfd));
1542 }
1543
1544 if (dev->has_meta_cap) {
1545 vfd = &dev->meta_cap_dev;
1546 snprintf(vfd->name, sizeof(vfd->name),
1547 "vivid-%03d-meta-cap", inst);
1548 vfd->fops = &vivid_fops;
1549 vfd->ioctl_ops = &vivid_ioctl_ops;
1550 vfd->device_caps = dev->meta_cap_caps;
1551 vfd->release = video_device_release_empty;
1552 vfd->v4l2_dev = &dev->v4l2_dev;
1553 vfd->queue = &dev->vb_meta_cap_q;
1554 vfd->lock = &dev->mutex;
1555 video_set_drvdata(vfd, dev);
1556 #ifdef CONFIG_MEDIA_CONTROLLER
1557 dev->meta_cap_pad.flags = MEDIA_PAD_FL_SINK;
1558 ret = media_entity_pads_init(&vfd->entity, 1,
1559 &dev->meta_cap_pad);
1560 if (ret)
1561 goto unreg_dev;
1562 #endif
> 1563 ret = video_register_device(vfd, VFL_TYPE_METADATA,
1564 meta_cap_nr[inst]);
1565 if (ret < 0)
1566 goto unreg_dev;
1567 v4l2_info(&dev->v4l2_dev,
1568 "V4L2 metadata capture device registered as %s\n",
1569 video_device_node_name(vfd));
1570 }
1571
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
1 year, 5 months