Date   

Re: [PATCH 4.4.y-cip] ARM: shmobile: defconfig: Restore debugfs support

Pavel Machek
 

Hi!

From: Geert Uytterhoeven <geert+renesas@...>

commit fa2cdb1762d15f701b83efa60b04f0d04e71bf89 upstream.

Since commit 0e4a459f56c32d3e ("tracing: Remove unnecessary DEBUG_FS
dependency"), CONFIG_DEBUG_FS is no longer auto-enabled. This breaks
booting Debian 9, as systemd needs debugfs:

[FAILED] Failed to mount /sys/kernel/debug.
See 'systemctl status sys-kernel-debug.mount' for details.
[DEPEND] Dependency failed for Local File Systems.
...
You are in emergGive root password for maintenance
(or press Control-D to continue):

Fix this by enabling CONFIG_DEBUG_FS explicitly.

See also commit 18977008f44c66bd ("ARM: multi_v7_defconfig: Restore
debugfs support").
Do we rely on these defconfigs? I can take it as it should not break
anything, but it should not really be too important for -cip project.

[It is "defconfig", not "suitable-config-for-debian-9" :-)].

Best regards,
Pavel

+++ b/arch/arm/configs/shmobile_defconfig
@@ -226,3 +226,4 @@ CONFIG_NLS_ISO8859_1=y
# CONFIG_ENABLE_WARN_DEPRECATED is not set
# CONFIG_ENABLE_MUST_CHECK is not set
# CONFIG_ARM_UNWIND is not set
+CONFIG_DEBUG_FS=y
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany


There is no CIP IRC weekly meeting today

masashi.kudo@cybertrust.co.jp <masashi.kudo@...>
 

Hi,

As was discussed last week, there is no CIP IRC weekly meeting today.

Best regards,
--
M. Kudo


Re: [linux-cip:linux-4.19.y-cip 7/17] drivers/gpu/drm/drm_atomic.c:1264:1: warning: no previous prototype for 'drm_atomic_get_old_private_obj_state'

Pavel Machek
 

Hi!

I have received a warning message mail from Kernel test robot. I have investigated this issue and found there were lots of warnings with architecture by following the steps mentioned in this mail.

Then I investigated this particular issue and found that issue is caused by bad commit done by me while backporting. The below backport commit has
extra functions from patch1(0001-drm-Add-drm_atomic_get_old-new_private_obj_state.patch), but the corresponding header is missing.

cip commit: cacc2a81b9872aa8830353110b1252021f124ae8
upstream commit: 1b27fbdde1df172dba604855c45078d741f8c858

I have attached 3 patches, that looks like fixes the issue mentioned by kernel robot.

How do we proceed here?
drop cip commit: cacc2a81b9872aa8830353110b1252021f124ae8 and apply the 3 patches to fix this issue?
No, let's not revert anything.

This is trivial fix for first issue, make it into patch:

diff --git a/include/drm/drm_atomic.h b/include/drm/drm_atomic.h
index c0b48e25a620..9042fdae9211 100644
--- a/include/drm/drm_atomic.h
+++ b/include/drm/drm_atomic.h
@@ -402,6 +402,12 @@ void drm_atomic_private_obj_fini(struct drm_private_obj *obj);
struct drm_private_state * __must_check
drm_atomic_get_private_obj_state(struct drm_atomic_state *state,
struct drm_private_obj *obj);
+struct drm_private_state *
+drm_atomic_get_old_private_obj_state(struct drm_atomic_state *state,
+ struct drm_private_obj *obj);
+struct drm_private_state *
+drm_atomic_get_new_private_obj_state(struct drm_atomic_state *state,
+ struct drm_private_obj *obj);

struct drm_connector *
drm_atomic_get_old_connector_for_encoder(struct drm_atomic_state
*state,

And this is somehow strange / non-trivial thingie. Make it into second
patch, and maybe try to explain what is going on there.

Best regards,
Pavel

@@ -656,6 +662,7 @@ void drm_state_dump(struct drm_device *dev, struct drm_printer *p);
(__i)++) \
for_each_if ((__state)->connectors[__i].ptr && \
((connector) = (__state)->connectors[__i].ptr, \
+ (void)(connector) /* Only to avoid unused-but-set-variable warning */, \
(old_connector_state) = (__state)->connectors[__i].old_state, \
(new_connector_state) = (__state)->connectors[__i].new_state, 1))

@@ -677,6 +684,7 @@ void drm_state_dump(struct drm_device *dev, struct drm_printer *p);
(__i)++) \
for_each_if ((__state)->connectors[__i].ptr && \
((connector) = (__state)->connectors[__i].ptr, \
+ (void)(connector) /* Only to avoid unused-but-set-variable warning */, \
(old_connector_state) = (__state)->connectors[__i].old_state, 1))

/**
@@ -697,7 +705,9 @@ void drm_state_dump(struct drm_device *dev, struct drm_printer *p);
(__i)++) \
for_each_if ((__state)->connectors[__i].ptr && \
((connector) = (__state)->connectors[__i].ptr, \
- (new_connector_state) = (__state)->connectors[__i].new_state, 1))
+ (void)(connector) /* Only to avoid unused-but-set-variable warning */, \
+ (new_connector_state) = (__state)->connectors[__i].new_state, \
+ (void)(new_connector_state) /* Only to avoid unused-but-set-variable warning */, 1))

/**
* for_each_oldnew_crtc_in_state - iterate over all CRTCs in an atomic update
@@ -717,7 +727,9 @@ void drm_state_dump(struct drm_device *dev, struct drm_printer *p);
(__i)++) \
for_each_if ((__state)->crtcs[__i].ptr && \
((crtc) = (__state)->crtcs[__i].ptr, \
+ (void)(crtc) /* Only to avoid unused-but-set-variable warning */, \
(old_crtc_state) = (__state)->crtcs[__i].old_state, \
+ (void)(old_crtc_state) /* Only to avoid unused-but-set-variable warning */, \
(new_crtc_state) = (__state)->crtcs[__i].new_state, 1))

/**
@@ -756,7 +768,9 @@ void drm_state_dump(struct drm_device *dev, struct drm_printer *p);
(__i)++) \
for_each_if ((__state)->crtcs[__i].ptr && \
((crtc) = (__state)->crtcs[__i].ptr, \
- (new_crtc_state) = (__state)->crtcs[__i].new_state, 1))
+ (void)(crtc) /* Only to avoid unused-but-set-variable warning */, \
+ (new_crtc_state) = (__state)->crtcs[__i].new_state, \
+ (void)(new_crtc_state) /* Only to avoid unused-but-set-variable warning */, 1))

/**
* for_each_oldnew_plane_in_state - iterate over all planes in an atomic update
@@ -776,6 +790,7 @@ void drm_state_dump(struct drm_device *dev, struct drm_printer *p);
(__i)++) \
for_each_if ((__state)->planes[__i].ptr && \
((plane) = (__state)->planes[__i].ptr, \
+ (void)(plane) /* Only to avoid unused-but-set-variable warning */, \
(old_plane_state) = (__state)->planes[__i].old_state,\
(new_plane_state) = (__state)->planes[__i].new_state, 1))

@@ -836,7 +851,9 @@ void drm_state_dump(struct drm_device *dev, struct drm_printer *p);
(__i)++) \
for_each_if ((__state)->planes[__i].ptr && \
((plane) = (__state)->planes[__i].ptr, \
- (new_plane_state) = (__state)->planes[__i].new_state, 1))
+ (void)(plane) /* Only to avoid unused-but-set-variable warning */, \
+ (new_plane_state) = (__state)->planes[__i].new_state, \
+ (void)(new_plane_state) /* Only to avoid unused-but-set-variable warning */, 1))

/**
* for_each_oldnew_private_obj_in_state - iterate over all private objects in an atomic update



--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany


Re: [linux-cip:linux-4.19.y-cip 7/17] drivers/gpu/drm/drm_atomic.c:1264:1: warning: no previous prototype for 'drm_atomic_get_old_private_obj_state'

Pavel Machek
 

Hi!

I have received a warning message mail from Kernel test robot. I have investigated this issue and found there were lots of warnings with architecture by following the steps mentioned in this mail.

Then I investigated this particular issue and found that issue is caused by bad commit done by me while backporting. The below backport commit has
extra functions from patch1(0001-drm-Add-drm_atomic_get_old-new_private_obj_state.patch), but the corresponding header is missing.

cip commit: cacc2a81b9872aa8830353110b1252021f124ae8
upstream commit: 1b27fbdde1df172dba604855c45078d741f8c858

I have attached 3 patches, that looks like fixes the issue mentioned by kernel robot.

How do we proceed here?
drop cip commit: cacc2a81b9872aa8830353110b1252021f124ae8 and apply the 3 patches to fix this issue?
First I want to make sure: we are talking about commit
60b4667275b60d92c760d48df95f5b80bbcfde6e? Because I don't see
cacc2a81b9872aa8830353110b1252021f124ae8 around.

Best regards,
Pavel

commit 60b4667275b60d92c760d48df95f5b80bbcfde6e
Author: Laurent Pinchart <laurent.pinchart@...>
Date: Wed Jul 22 17:34:39 2020 +0100

drm: Add drm_atomic_get_(old|new)_connector_for_encoder() helpers

commit 1b27fbdde1df172dba604855c45078d741f8c858 upstream.

Add functions to the atomic core to retrieve the old and new
connectors associated with an encoder in a drm_atomic_state. This
is useful for encoders and bridges that need to access the
connector, for instance for the drm_display_info.


--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany


Re: [PATCH] drm: of: Fix linking when CONFIG_OF is not set

Pavel Machek
 

Hi!

I assume this patch is for 4.19-cip?

commit 528d06d41b80a4acb2a9efd33bfc87495147f75e upstream.

The new helper drm_of_lvds_get_dual_link_pixel_order() introduced in
commit 6529007522de has a fallback stub when CONFIG_OF is not set, but
the stub is declared in drm_of.h without a static inline. This causes
multiple definitions of the function to be linked when the CONFIG_OF
option isn't set. Fix it by making the stub static inline.
So this is pretty obvious, and I'll likely apply it.

Best regards,
Pavel


diff --git a/include/drm/drm_of.h b/include/drm/drm_of.h
index 8ec7ca6d2369..b9b093add92e 100644
--- a/include/drm/drm_of.h
+++ b/include/drm/drm_of.h
@@ -92,8 +92,9 @@ static inline int drm_of_find_panel_or_bridge(const struct device_node *np,
return -EINVAL;
}

-int drm_of_lvds_get_dual_link_pixel_order(const struct device_node *port1,
- const struct device_node *port2)
+static inline int
+drm_of_lvds_get_dual_link_pixel_order(const struct device_node *port1,
+ const struct device_node *port2)
{
return -EINVAL;
}
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany


[PATCH] drm: of: Fix linking when CONFIG_OF is not set

Biju Das <biju.das.jz@...>
 

From: Laurent Pinchart <laurent.pinchart+renesas@...>

commit 528d06d41b80a4acb2a9efd33bfc87495147f75e upstream.

The new helper drm_of_lvds_get_dual_link_pixel_order() introduced in
commit 6529007522de has a fallback stub when CONFIG_OF is not set, but
the stub is declared in drm_of.h without a static inline. This causes
multiple definitions of the function to be linked when the CONFIG_OF
option isn't set. Fix it by making the stub static inline.

Fixes: 6529007522de ("drm: of: Add drm_of_lvds_get_dual_link_pixel_order")
Reported-by: kbuild test robot <lkp@...>
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@...>
Reviewed-by: Fabrizio Castro <fabrizio.castro@...>
Reviewed-by: Chris Wilson <chris@...>
Signed-off-by: Dave Airlie <airlied@...>
Link: https://patchwork.freedesktop.org/patch/msgid/20191219103703.8547-1-laurent.pinchart+renesas@ideasonboard.com
Signed-off-by: Biju Das <biju.das.jz@...>
Reported-by: kernel test robot <lkp@...>
---
include/drm/drm_of.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/include/drm/drm_of.h b/include/drm/drm_of.h
index 8ec7ca6d2369..b9b093add92e 100644
--- a/include/drm/drm_of.h
+++ b/include/drm/drm_of.h
@@ -92,8 +92,9 @@ static inline int drm_of_find_panel_or_bridge(const struct device_node *np,
return -EINVAL;
}

-int drm_of_lvds_get_dual_link_pixel_order(const struct device_node *port1,
- const struct device_node *port2)
+static inline int
+drm_of_lvds_get_dual_link_pixel_order(const struct device_node *port1,
+ const struct device_node *port2)
{
return -EINVAL;
}
--
2.17.1


Re: [linux-cip:linux-4.19.y-cip 7/17] drivers/gpu/drm/drm_atomic.c:1264:1: warning: no previous prototype for 'drm_atomic_get_old_private_obj_state'

Biju Das <biju.das.jz@...>
 

Hi All,

I have received a warning message mail from Kernel test robot. I have investigated this issue and found there were lots of warnings with architecture by following the steps mentioned in this mail.

Then I investigated this particular issue and found that issue is caused by bad commit done by me while backporting. The below backport commit has
extra functions from patch1(0001-drm-Add-drm_atomic_get_old-new_private_obj_state.patch), but the corresponding header is missing.

cip commit: cacc2a81b9872aa8830353110b1252021f124ae8
upstream commit: 1b27fbdde1df172dba604855c45078d741f8c858

I have attached 3 patches, that looks like fixes the issue mentioned by kernel robot.

How do we proceed here?
drop cip commit: cacc2a81b9872aa8830353110b1252021f124ae8 and apply the 3 patches to fix this issue?

Please share your views.

Regards,
Biju

-----Original Message-----
From: kernel test robot <lkp@...>
Sent: 09 August 2020 15:13
To: Laurent Pinchart <laurent.pinchart@...>
Cc: kbuild-all@...; Pavel Machek <pavel@...>; Daniel Vetter
<daniel@...>; Sean Paul <seanpaul@...>; Biju Das
<biju.das.jz@...>
Subject: [linux-cip:linux-4.19.y-cip 7/17]
drivers/gpu/drm/drm_atomic.c:1264:1: warning: no previous prototype for
'drm_atomic_get_old_private_obj_state'

tree: https://git.kernel.org/pub/scm/linux/kernel/git/cip/linux-cip.git linux-
4.19.y-cip
head: 72750517bc5f1718ce3cb3fa75d4cadc05d27eee
commit: 60b4667275b60d92c760d48df95f5b80bbcfde6e [7/17] drm: Add
drm_atomic_get_(old|new)_connector_for_encoder() helpers
config: riscv-randconfig-r034-20200809 (attached as .config)
compiler: riscv32-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-
tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 60b4667275b60d92c760d48df95f5b80bbcfde6e
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0
make.cross ARCH=riscv

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...>

All warnings (new ones prefixed by >>):

drivers/gpu/drm/drm_atomic.c:1264:1: warning: no previous prototype
for 'drm_atomic_get_old_private_obj_state' [-Wmissing-prototypes]
1264 | drm_atomic_get_old_private_obj_state(struct drm_atomic_state
*state,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/drm_atomic.c:1286:1: warning: no previous prototype
for 'drm_atomic_get_new_private_obj_state' [-Wmissing-prototypes]
1286 | drm_atomic_get_new_private_obj_state(struct drm_atomic_state
*state,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/drm_atomic.c: In function 'drm_atomic_print_state':
drivers/gpu/drm/drm_atomic.c:2184:24: warning: variable 'connector' set
but not used [-Wunused-but-set-variable]
2184 | struct drm_connector *connector;
| ^~~~~~~~~
drivers/gpu/drm/drm_atomic.c:2182:19: warning: variable 'crtc' set but not
used [-Wunused-but-set-variable]
2182 | struct drm_crtc *crtc;
| ^~~~
drivers/gpu/drm/drm_atomic.c:2180:20: warning: variable 'plane' set but
not used [-Wunused-but-set-variable]
2180 | struct drm_plane *plane;
| ^~~~~
drivers/gpu/drm/drm_atomic.c: In function 'complete_signaling':
drivers/gpu/drm/drm_atomic.c:2624:19: warning: variable 'crtc' set but not
used [-Wunused-but-set-variable]
2624 | struct drm_crtc *crtc;
| ^~~~

vim +/drm_atomic_get_old_private_obj_state +1264
drivers/gpu/drm/drm_atomic.c

1254
1255/**
1256 * drm_atomic_get_old_private_obj_state
1257 * @state: global atomic state object
1258 * @obj: private_obj to grab
1259 *
1260 * This function returns the old private object state for the given
private_obj,
1261 * or NULL if the private_obj is not part of the global atomic state.
1262 */
1263struct drm_private_state *
1264drm_atomic_get_old_private_obj_state(struct drm_atomic_state
*state,
1265 struct drm_private_obj *obj)
1266{
1267int i;
1268
1269for (i = 0; i < state->num_private_objs; i++)
1270if (obj == state->private_objs[i].ptr)
1271return state->private_objs[i].old_state;
1272
1273return NULL;
1274}
1275EXPORT_SYMBOL(drm_atomic_get_old_private_obj_state);
1276
1277/**
1278 * drm_atomic_get_new_private_obj_state
1279 * @state: global atomic state object
1280 * @obj: private_obj to grab
1281 *
1282 * This function returns the new private object state for the given
private_obj,
1283 * or NULL if the private_obj is not part of the global atomic state.
1284 */
1285struct drm_private_state *
1286drm_atomic_get_new_private_obj_state(struct drm_atomic_state
*state,
1287 struct drm_private_obj *obj)
1288{
1289int i;
1290
1291for (i = 0; i < state->num_private_objs; i++)
1292if (obj == state->private_objs[i].ptr)
1293return state->private_objs[i].new_state;
1294
1295return NULL;
1296}
1297EXPORT_SYMBOL(drm_atomic_get_new_private_obj_state);
1298

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

Renesas Electronics Europe GmbH, Geschaeftsfuehrer/President: Carsten Jauch, Sitz der Gesellschaft/Registered office: Duesseldorf, Arcadiastrasse 10, 40472 Duesseldorf, Germany, Handelsregister/Commercial Register: Duesseldorf, HRB 3708 USt-IDNr./Tax identification no.: DE 119353406 WEEE-Reg.-Nr./WEEE reg. no.: DE 14978647


[ANNOUNCE] Release v4.19.138-cip32 and v4.4.231-cip48-rebase

Nobuhiro Iwamatsu
 

Hi,

CIP kernel team has released Linux kernel v4.19.138-cip32 and v4.4.231-cip48-rebase.
The linux-4.19.y-cip tree has been updated base version from v4.19.134 to v4.19.138,
and the linux-4.4.y-cip tree has been updated base version from
v4.4.230 to v4.4.231.
And In linux-4.4.y-cip, a patch for adding the updatitng DU and touch panel functions for RZ/G1 has been added.

You can get this release via the git tree at:

v4.19.138-cip32:
repository:
https://git.kernel.org/pub/scm/linux/kernel/git/cip/linux-cip.git
branch:
linux-4.19.y-cip
commit hash:
87e30ad380b2da89b8fb27e61a38c467a628b102
added commits:
CIP: Bump version suffix to -cip32 after merge from stable
drm: of: Fix double-free bug

v4.4.231-cip48-rebase:
repository:
https://git.kernel.org/pub/scm/linux/kernel/git/cip/linux-cip.git
branch:
linux-4.4.y-cip
commit hash:
7d8ea507fea1b69557994f3dc0d96d2505af95ea
added commits:
CIP: Bump version suffix to -cip48 after merge from stable
ARM: dts: iwg22d-sodimm: Enable touchscreen
ARM: dts: iwg22d-sodimm: Enable LCD panel
ARM: shmobile: defconfig: Enable support for panels from EDT
ARM: shmobile: defconfig: Enable frame buffer console for armadillo800eva
drm: rcar-du: Use the DRM panel API
drm: rcar-du: Support panels connected directly to the DPAD outputs
drm/panel: simple: Add EDT panel support
dt-bindings: display: Add bindings for EDT panel
of: add node name compare helper functions
drm: Add an encoder and connector type enum for DPI.
serial: sh-sci: Make sure status register SCxSR is read in correct sequence

Best regards,
Nobuhiro


Re: [cip-kernel-config PATCH] qemu_cip_defconfig: Add EFI_STUB to config

Nobuhiro Iwamatsu
 

Hi,

-----Original Message-----
From: cip-dev@... [mailto:cip-dev@...] On Behalf Of Quirin Gylstorff
Sent: Thursday, August 6, 2020 11:27 PM
To: cip-dev@...; sangorrin daniel(サンゴリン ダニエル □SWC◯ACT)
<daniel.sangorrin@...>; jan.kiszka@...
Subject: Re: [cip-dev] [cip-kernel-config PATCH] qemu_cip_defconfig: Add EFI_STUB to config



On 8/6/20 8:46 AM, Nobuhiro Iwamatsu wrote:
Hi,

Thanks for your patch.

-----Original Message-----
From: cip-dev@... [mailto:cip-dev@...] On Behalf Of Quirin Gylstorff
Sent: Monday, August 3, 2020 7:12 PM
To: cip-dev@...; sangorrin daniel(サンゴリン ダニエル □SWC◯ACT)
<daniel.sangorrin@...>; jan.kiszka@...
Cc: Quirin Gylstorff <quirin.gylstorff@...>
Subject: [cip-dev] [cip-kernel-config PATCH] qemu_cip_defconfig: Add EFI_STUB to config

From: Quirin Gylstorff <quirin.gylstorff@...>

If EFI_STUB is not active booting QEMU with OVMF efi will fail
with the following error message `KVM internal error. Suberror: 3`.

OVMF efi is used in isar-cip-core to demonstrate secure-boot with
a unified kernel image.

Signed-off-by: Quirin Gylstorff <quirin.gylstorff@...>
---
4.19.y-cip/x86/cip_qemu_defconfig | 1 +
1 file changed, 1 insertion(+)
Please update cip_qemu.sources too.
When i try to generate the sources - all .c and asm files are no longer
part of the cip-qemu.sources. Did I miss something? Or should I try
again like the last time this happened?
Thanks for your check.
Sorry, I wanted to check if there was a fix in cip_qemu.sources.
I applied this patch.

Thanks,
Quirin
Best regards,
Nobuhiro


Re: [cip-kernel-config PATCH] qemu_cip_defconfig: Add EFI_STUB to config

Quirin Gylstorff
 

On 8/6/20 8:46 AM, Nobuhiro Iwamatsu wrote:
Hi,
Thanks for your patch.

-----Original Message-----
From: cip-dev@... [mailto:cip-dev@...] On Behalf Of Quirin Gylstorff
Sent: Monday, August 3, 2020 7:12 PM
To: cip-dev@...; sangorrin daniel(サンゴリン ダニエル □SWC◯ACT)
<daniel.sangorrin@...>; jan.kiszka@...
Cc: Quirin Gylstorff <quirin.gylstorff@...>
Subject: [cip-dev] [cip-kernel-config PATCH] qemu_cip_defconfig: Add EFI_STUB to config

From: Quirin Gylstorff <quirin.gylstorff@...>

If EFI_STUB is not active booting QEMU with OVMF efi will fail
with the following error message `KVM internal error. Suberror: 3`.

OVMF efi is used in isar-cip-core to demonstrate secure-boot with
a unified kernel image.

Signed-off-by: Quirin Gylstorff <quirin.gylstorff@...>
---
4.19.y-cip/x86/cip_qemu_defconfig | 1 +
1 file changed, 1 insertion(+)
Please update cip_qemu.sources too.
When i try to generate the sources - all .c and asm files are no longer part of the cip-qemu.sources. Did I miss something? Or should I try again like the last time this happened?

Best regards,
Nobuhiro
Thanks,
Quirin


Re: [cip-kernel-config PATCH] qemu_cip_defconfig: Add EFI_STUB to config

Nobuhiro Iwamatsu
 

Hi,

Thanks for your patch.

-----Original Message-----
From: cip-dev@... [mailto:cip-dev@...] On Behalf Of Quirin Gylstorff
Sent: Monday, August 3, 2020 7:12 PM
To: cip-dev@...; sangorrin daniel(サンゴリン ダニエル □SWC◯ACT)
<daniel.sangorrin@...>; jan.kiszka@...
Cc: Quirin Gylstorff <quirin.gylstorff@...>
Subject: [cip-dev] [cip-kernel-config PATCH] qemu_cip_defconfig: Add EFI_STUB to config

From: Quirin Gylstorff <quirin.gylstorff@...>

If EFI_STUB is not active booting QEMU with OVMF efi will fail
with the following error message `KVM internal error. Suberror: 3`.

OVMF efi is used in isar-cip-core to demonstrate secure-boot with
a unified kernel image.

Signed-off-by: Quirin Gylstorff <quirin.gylstorff@...>
---
4.19.y-cip/x86/cip_qemu_defconfig | 1 +
1 file changed, 1 insertion(+)
Please update cip_qemu.sources too.

Best regards,
Nobuhiro


Re: CIP IRC weekly meeting today

Akihiro Suzuki
 

Hi Kudo-san,

Sorry, I will be absent today's IRC meeting because I've got a plan already today.
SW Updates WG don't have any updates this week.

Best regards,
Suzuki

-----Original Message-----
From: cip-dev@... <cip-dev@...> On Behalf Of masashi.kudo@...
Sent: Thursday, August 6, 2020 8:51 AM
To: cip-dev@...
Subject: [cip-dev] CIP IRC weekly meeting today

Hi all,

Kindly be reminded to attend the weekly meeting through IRC to discuss technical topics with CIP kernel today.

*Please note that the IRC meeting was rescheduled to UTC (GMT) 09:00 starting from the first week of Apr. according to TSC meeting*
https://www.timeanddate.com/worldclock/meetingdetails.html?year=2020&month=8&day=6&hour=9&min=0&sec=0&p1=224&p2=179&p3=136&p4=37&p5=241&p6=248

USWest USEast UK DE TW JP
02:00 05:00 10:00 11:00 17:00 18:00

Channel:
* irc:chat.freenode.net:6667/cip

Last meeting minutes:
https://irclogs.baserock.org/meetings/cip/2020/07/cip.2020-07-30-09.00.log.html

Agenda:

* Action item
1. Combine root filesystem with kselftest binary - iwamatsu
2. Post LTP results to KernelCI - patersonc

* Kernel maintenance updates
* Kernel testing
* Software update
* CIP Security
* AOB

The meeting will take 30 min, although it can be extended to an hour if it makes sense and those involved in the topics can stay. Otherwise, the topic will be taken offline or in the next meeting.

Best regards,
--
M. Kudo
Cybertrust Japan Co., Ltd.


CIP IRC weekly meeting today

masashi.kudo@cybertrust.co.jp <masashi.kudo@...>
 

Hi all,

Kindly be reminded to attend the weekly meeting through IRC to discuss technical topics with CIP kernel today.

*Please note that the IRC meeting was rescheduled to UTC (GMT) 09:00 starting from the first week of Apr. according to TSC meeting*
https://www.timeanddate.com/worldclock/meetingdetails.html?year=2020&month=8&day=6&hour=9&min=0&sec=0&p1=224&p2=179&p3=136&p4=37&p5=241&p6=248

USWest USEast UK DE TW JP
02:00 05:00 10:00 11:00 17:00 18:00

Channel:
* irc:chat.freenode.net:6667/cip

Last meeting minutes:
https://irclogs.baserock.org/meetings/cip/2020/07/cip.2020-07-30-09.00.log.html

Agenda:

* Action item
1. Combine root filesystem with kselftest binary - iwamatsu
2. Post LTP results to KernelCI - patersonc

* Kernel maintenance updates
* Kernel testing
* Software update
* CIP Security
* AOB

The meeting will take 30 min, although it can be extended to an hour if it makes sense and those involved in the topics can stay. Otherwise, the topic will be taken offline or in the next meeting.

Best regards,
--
M. Kudo
Cybertrust Japan Co., Ltd.


[isar-cip-core] security-customizations: Recipe to apply security configurations

Venkata Pyla
 

From: venkata pyla <venkata.pyla@...>

This recipe will apply security policies* to the reference image
that will be used for IEC62443-4-2 Evaluation

*Security policies:
1. Enforcing strong password to user accounts
2. Lock user accounts for failed login attempts
3. Terminate remote session for inactive time period
4. Limit the concurrent login sessions
5. Warn audit stroage failure

Signed-off-by: venkata pyla <venkata.pyla@...>
---
.../images/cip-core-image-security.bb | 2 +-
.../security-customizations/files/postinst | 51 +++++++++++++++++++
.../security-customizations.bb | 18 +++++++
3 files changed, 70 insertions(+), 1 deletion(-)
create mode 100644 recipes-core/security-customizations/files/postinst
create mode 100644 recipes-core/security-customizations/security-customizations.bb

diff --git a/recipes-core/images/cip-core-image-security.bb b/recipes-core/images/cip-core-image-security.bb
index a17c522..61ddc39 100644
--- a/recipes-core/images/cip-core-image-security.bb
+++ b/recipes-core/images/cip-core-image-security.bb
@@ -13,7 +13,7 @@ inherit image

DESCRIPTION = "CIP Core image including security packages"

-IMAGE_INSTALL += "customizations"
+IMAGE_INSTALL += "security-customizations"

# Debian packages that provide security features
IMAGE_PREINSTALL += " \
diff --git a/recipes-core/security-customizations/files/postinst b/recipes-core/security-customizations/files/postinst
new file mode 100644
index 0000000..3699ba2
--- /dev/null
+++ b/recipes-core/security-customizations/files/postinst
@@ -0,0 +1,51 @@
+#!/bin/sh
+#
+# CIP Security, generic profile
+# Security Package configurations
+#
+
+echo "CIP Core Security Image (login: root/root)" > /etc/issue
+
+HOSTNAME=demo
+echo "$HOSTNAME" > /etc/hostname
+echo "127.0.0.1 $HOSTNAME" >> /etc/hosts
+
+# CR1.7: Strength of password-based authentication
+# Pam configuration to enforce password strength
+PAM_PWD_FILE="/etc/pam.d/common-password"
+pam_cracklib_config="password requisite pam_cracklib.so retry=3 minlen=8 maxrepeat=3 ucredit=-1 lcredit=-1 dcredit=-1 ocredit=-1 difok=3 gecoscheck=1 reject_username enforce_for_root"
+if grep -c "pam_cracklib.so" "${PAM_PWD_FILE}";then
+ sed -i '/pam_cracklib.so/ s/^#*/#/' "${PAM_PWD_FILE}"
+fi
+sed -i "0,/^password.*/s/^password.*/${pam_cracklib_config}\n&/" "${PAM_PWD_FILE}"
+
+# CR1.11: Unsuccessful login attempts
+# Lock user account after unsuccessful login attempts
+PAM_AUTH_FILE="/etc/pam.d/common-auth"
+pam_tally="auth required pam_tally2.so deny=3 even_deny_root unlock_time=60 root_unlock_time=60"
+if grep -c "pam_tally2.so" "${PAM_AUTH_FILE}";then
+ sed -i '/pam_tally2/ s/^#*/#/' "${PAM_AUTH_FILE}"
+fi
+sed -i "0,/^auth.*/s/^auth.*/${pam_tally}\n&/" "${PAM_AUTH_FILE}"
+
+# CR2.6: Remote session termination
+# Terminate remote session after inactive time period
+SSHD_CONFIG="/etc/ssh/sshd_config"
+alive_interval=$(sed -n '/ClientAliveInterval/p' "${SSHD_CONFIG}")
+alive_countmax=$(sed -n '/ClientAliveCountMax/p' "${SSHD_CONFIG}")
+sed -i "/${alive_interval}/c ClientAliveInterval 120" "${SSHD_CONFIG}"
+sed -i "/${alive_countmax}/c ClientAliveCountMax 0" "${SSHD_CONFIG}"
+
+# CR2.7: Concurrent session control
+# Limit the concurrent login sessions
+LIMITS_CONFIG="/etc/security/limits.conf"
+echo "* hard maxlogins 2" >> ${LIMITS_CONFIG}
+
+# CR2.9: Audit storage capacity
+# CR2.9 RE-1: Warn when audit record storage capacity threshold reached
+AUDIT_CONF_FILE="/etc/audit/auditd.conf"
+sed -i 's/space_left_action = .*/space_left_action = SYSLOG/' $AUDIT_CONF_FILE
+sed -i 's/admin_space_left_action = .*/admin_space_left_action = SYSLOG/' $AUDIT_CONF_FILE
+
+# CR2.10: Response to audit processing failures
+sed -i 's/disk_error_action = .*/disk_error_action = SYSLOG/' $AUDIT_CONF_FILE
diff --git a/recipes-core/security-customizations/security-customizations.bb b/recipes-core/security-customizations/security-customizations.bb
new file mode 100644
index 0000000..dbb06d9
--- /dev/null
+++ b/recipes-core/security-customizations/security-customizations.bb
@@ -0,0 +1,18 @@
+#
+# CIP Security, generic profile
+#
+# Copyright (c) Toshiba Corporation, 2020
+#
+# Authors:
+# Venkata Pyla <venkata.pyla@...>#
+#
+# SPDX-License-Identifier: MIT
+#
+
+inherit dpkg-raw
+
+DESCRIPTION = "CIP Security image for IEC62443-4-2 evaluation"
+
+SRC_URI = " file://postinst"
+
+DEBIAN_DEPENDS = "sshd-regen-keys"
--
2.20.1

The information contained in this e-mail message and in any
attachments/annexure/appendices is confidential to the
recipient and may contain privileged information.
If you are not the intended recipient, please notify the
sender and delete the message along with any
attachments/annexure/appendices. You should not disclose,
copy or otherwise use the information contained in the
message or any annexure. Any views expressed in this e-mail
are those of the individual sender except where the sender
specifically states them to be the views of
Toshiba Software India Pvt. Ltd. (TSIP),Bangalore.

Although this transmission and any attachments are believed to be
free of any virus or other defect that might affect any computer
system into which it is received and opened, it is the responsibility
of the recipient to ensure that it is virus free and no responsibility
is accepted by Toshiba Embedded Software India Pvt. Ltd, for any loss or
damage arising in any way from its use.


Re: [isar-cip-core] remove remaining configs from isar-cip-core

Quirin Gylstorff
 

Sure, i will look into it. You get a Patch if something is missing.

Quirin

Von: daniel.sangorrin@...
Gesendet: Mittwoch, 5. August 2020 03:28
An: cip-dev@...
Cc: Kiszka, Jan (CT RDA IOT SES-DE)
Betreff: RE: [cip-dev] [isar-cip-core] remove remaining configs from isar-cip-core

Hi Quirin,

> -----Original Message-----
> From: cip-dev@... <cip-dev@...> On Behalf Of Quirin Gylstorff
> Sent: Tuesday, August 4, 2020 10:25 PM
> To: cip-dev@...
> Cc: jan.kiszka@...
> Subject: Re: [cip-dev] [isar-cip-core] remove remaining configs from isar-cip-core
>
>
>
> On 8/4/20 6:47 AM, Daniel Sangorrin wrote:
> > Hi Jan,
> >
> > This patch just removes the already unused defconfigs from
> > isar-cip-core
> >
> > [isar-cip-core] kernel: remove configs that are already in
> >
> > I didn't know what to do with bbb_defconfig because it does not seem
> > to be used at all by isar-cip-core (maybe it is in a rather obscure way).
> > However, that should also be removed and use cip_bbb_defconfig.
> >
> > Thanks,
> > Daniel
> >
>
>
> In
> https://gitlab.com/cip-project/cip-core/isar-cip-core/-/tree/cip-sw-updates/swupdate
> bbb is used as demo system.

Thanks, I guess I was confused because there were no KERNEL_DEFCONFIG definitions.
But it seems that linux-cip-common.inc sets up one by default if you dont specify it
KERNEL_DEFCONFIG ?= "${MACHINE}_defconfig"

I see quite a few differences between
https://gitlab.com/cip-project/cip-kernel/cip-kernel-config.git's cip-kernel-config/4.19.y-cip/arm/cip_bbb_defconfig
and isar-cip-core's bbb_defconfig.

Could you try using cip_bbb_defconfig and see if you need some extra configuration for software updates to work?

Thanks,
Daniel


Re: [isar-cip-core] remove remaining configs from isar-cip-core

Daniel Sangorrin <daniel.sangorrin@...>
 

Hi Quirin,

-----Original Message-----
From: cip-dev@... <cip-dev@...> On Behalf Of Quirin Gylstorff
Sent: Tuesday, August 4, 2020 10:25 PM
To: cip-dev@...
Cc: jan.kiszka@...
Subject: Re: [cip-dev] [isar-cip-core] remove remaining configs from isar-cip-core



On 8/4/20 6:47 AM, Daniel Sangorrin wrote:
Hi Jan,

This patch just removes the already unused defconfigs from
isar-cip-core

[isar-cip-core] kernel: remove configs that are already in

I didn't know what to do with bbb_defconfig because it does not seem
to be used at all by isar-cip-core (maybe it is in a rather obscure way).
However, that should also be removed and use cip_bbb_defconfig.

Thanks,
Daniel

In
https://gitlab.com/cip-project/cip-core/isar-cip-core/-/tree/cip-sw-updates/swupdate
bbb is used as demo system.
Thanks, I guess I was confused because there were no KERNEL_DEFCONFIG definitions.
But it seems that linux-cip-common.inc sets up one by default if you dont specify it
KERNEL_DEFCONFIG ?= "${MACHINE}_defconfig"

I see quite a few differences between
https://gitlab.com/cip-project/cip-kernel/cip-kernel-config.git's cip-kernel-config/4.19.y-cip/arm/cip_bbb_defconfig
and isar-cip-core's bbb_defconfig.

Could you try using cip_bbb_defconfig and see if you need some extra configuration for software updates to work?

Thanks,
Daniel


[isar-cip-core][PATCH 3/3] testing: Add test.yml

Nobuhiro Iwamatsu
 

Add YAML to add the test application to cip-core-image, and create the
cip-core-image-test image.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@...>
---
kas/opt/test.yml | 15 +++++++++++++++
1 file changed, 15 insertions(+)
create mode 100644 kas/opt/test.yml

diff --git a/kas/opt/test.yml b/kas/opt/test.yml
new file mode 100644
index 0000000..c9eeb83
--- /dev/null
+++ b/kas/opt/test.yml
@@ -0,0 +1,15 @@
+#
+# CIP Core, generic profile
+#
+# Copyright (c) Siemens AG, 2019
+#
+# Authors:
+# Jan Kiszka <jan.kiszka@...>
+#
+# SPDX-License-Identifier: MIT
+#
+
+header:
+ version: 8
+
+target: cip-core-image-test
--
2.27.0


[isar-cip-core][PATCH 2/3] customizations: Remove rt-tests and stress-ng from DEBIAN_DEPENDS

Nobuhiro Iwamatsu
 

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@...>
---
recipes-core/customizations/customizations.bb | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/recipes-core/customizations/customizations.bb b/recipes-core/customizations/customizations.bb
index 38881fb..932b11c 100644
--- a/recipes-core/customizations/customizations.bb
+++ b/recipes-core/customizations/customizations.bb
@@ -11,7 +11,7 @@

inherit dpkg-raw

-DESCRIPTION = "CIP Core image demo & test customizations"
+DESCRIPTION = "CIP Core image demo & customizations"

SRC_URI = " \
file://postinst \
@@ -21,8 +21,7 @@ SRC_URI = " \
DEPENDS += "sshd-regen-keys"

DEBIAN_DEPENDS = " \
- ifupdown, isc-dhcp-client, net-tools, iputils-ping, ssh, sshd-regen-keys, \
- rt-tests, stress-ng"
+ ifupdown, isc-dhcp-client, net-tools, iputils-ping, ssh, sshd-regen-keys"

do_install() {
install -v -d ${D}/etc/network/interfaces.d
--
2.27.0


[isar-cip-core][PATCH 1/3] cip-core-image-test: Add recipe

Nobuhiro Iwamatsu
 

This recipe provides an image for testing.
If use this, it will create an image containing LTP(ltp-full), rt-tests and stress-ng.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@...>
---
recipes-core/images/cip-core-image-test.bb | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
create mode 100644 recipes-core/images/cip-core-image-test.bb

diff --git a/recipes-core/images/cip-core-image-test.bb b/recipes-core/images/cip-core-image-test.bb
new file mode 100644
index 0000000..e2b15fc
--- /dev/null
+++ b/recipes-core/images/cip-core-image-test.bb
@@ -0,0 +1,18 @@
+#
+# CIP Core, generic profile
+#
+# Copyright (c) Siemens AG, 2019
+#
+# Authors:
+# Jan Kiszka <jan.kiszka@...>
+#
+# SPDX-License-Identifier: MIT
+#
+#
+inherit dpkg-raw
+require cip-core-image.bb
+
+DESCRIPTION = "CIP Core image including test packages"
+
+IMAGE_INSTALL += "ltp-full"
+DEBIAN_DEPENDS += "rt-tests, stress-ng"
--
2.27.0


[PATCH 3/3] testing: Add test.yml

Nobuhiro Iwamatsu
 

Add YAML to add the test application to cip-core-image, and create the
cip-core-image-test image.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@...>
---
kas/opt/test.yml | 15 +++++++++++++++
1 file changed, 15 insertions(+)
create mode 100644 kas/opt/test.yml

diff --git a/kas/opt/test.yml b/kas/opt/test.yml
new file mode 100644
index 0000000..c9eeb83
--- /dev/null
+++ b/kas/opt/test.yml
@@ -0,0 +1,15 @@
+#
+# CIP Core, generic profile
+#
+# Copyright (c) Siemens AG, 2019
+#
+# Authors:
+# Jan Kiszka <jan.kiszka@...>
+#
+# SPDX-License-Identifier: MIT
+#
+
+header:
+ version: 8
+
+target: cip-core-image-test
--
2.27.0

4581 - 4600 of 9694