Project

General

Profile

Actions

Bug #4448

open

Support of __always_inline functions

Added by Ilya Shchepetkov over 10 years ago. Updated over 10 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Start date:
08/23/2013
Due date:
% Done:

0%

Estimated time:
Detected in build:
svn
Platform:
Published in build:

Description

111_1a model contains a large number of __always_inline functions:

before call(static __always_inline unsigned long __copy_to_user_inatomic(..))
before call(static __always_inline int copy_to_user(..))
before call(static __always_inline unsigned long __copy_from_user_nocache(..))
before call(static __always_inline unsigned long __copy_from_user_inatomic_nocache(..))
...

Currently aspeсtator does not support __always_inline macro, and so these functions can't be instrumented. We should fix this.

Actions #1

Updated by Evgeny Novikov over 10 years ago

  • Project changed from C Instrumentation Framework to Linux Kernel Safety RuleDB
  • Assignee deleted (Evgeny Novikov)
More over Aspectator doesn't support preprocessing stuff at all. And here I see two problems:
  1. Aspectator doesn't warn when there is more then one type specifier among declaration specifiers (__always_inline is treated as a typedef name and then unsigned long is also treated as a type specifier). C standard prohibits this. And this a real bug in Aspectator.
  2. There is aspect preprocessing that can be used absolutely in the same way as standard preprocessing. So rule modules can use __always_inline aspect macro iff it will be defined in, say, the kernel model. Also it might be possible to run standard preprocessor on aspect files after aspect preprocessor, providing compilation options, say, from a compilation command for some C file of a driver, but it should be done accurately since standard preprocessor constructs can be used in advice bodies as well.

BTW, what's wrong with __copy_from_user_nocache function?

Actions #2

Updated by Ilya Shchepetkov over 10 years ago

  • Description updated (diff)

__copy_from_user_nocache function was listed in error.

Actions

Also available in: Atom PDF