Error Forbidden Warning Linux Kernel
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Compiler error, with 3.0.101 kernel using gcc 4.9 up vote 0 down vote favorite Here is the error fs/fat/dir.c: In function 'fat_dir_empty': fs/fat/dir.c:124:8: warning: 'de' may be used uninitialized in this function [-Wmaybe-uninitialized] error, forbidden warning: dir.c:124 static inline int fat_get_entry(struct inode *dir, loff_t *pos, struct buffer_head **bh, struct msdos_dir_entry **de) { /* Fast stuff first */ if (*bh && *de && (*de - (struct msdos_dir_entry *)(*bh)->b_data) < MSDOS_SB(dir->i_sb)->dir_per_block - 1) { *pos += sizeof(struct msdos_dir_entry); (*de)++; return 0; } return fat__get_entry(dir, pos, bh, de); } (*de)++; is the issue I don't understand, 3.4 with same coding compiles just fine. Any help with this would be appreciated. UPDATE: After reading, http://lwn.net/Articles/529954/ I was running with -O3 optimization, which effects -Wmaybe-uninitialized UPDATE 2: vfat builds as a module, no problem. Only have issue as a built-in. I wonder why that would be? linux-kernel gcc-warning gcc4.9 share|improve this question edited Jan 24 '15 at 6:22 asked Jan 22 '15 at 23:54 Jcfunk 265 You posted the excerpt from the code that is not in 3.0.101 as I can see. The patch that modifies it is f08b4988f229f (fs/fat: fix all other checkpatch issues in dir.c). Moreover, the issue is not at the line you mentioned. Read carefully what compiler tells you. –Andy Shevchenko Jan 23 '15 at 9:17 Yes, edited in attem
[M] /home/kk/udp_probe/udp_probe.o /home/kk/udp_probe/udp_probe.c: In function 'kp_init': /home/kk/udp_probe/udp_probe.c:36:18: warning: assignment makes pointer from integer without a http://stackoverflow.com/questions/28100806/compiler-error-with-3-0-101-kernel-using-gcc-4-9 cast [enabled by default] error, forbidden warning: udp_probe.c:36 make[2]: *** [/home/kk/udp_probe/udp_probe.o] 错误 1 make[1]: *** [_module_/home/kk/udp_probe] 错误 2 make[1]:正在离开目录 `/media/000617990000DB90/403a/source/kernel' http://abcdxyzk.github.io/blog/2015/08/10/arm-gcc-warning/ make: *** [all] 错误 2 修改 scripts/gcc-wrapper.py 去掉 interpret_warning 函数中的如下部分 1 2 3 4 5 6 7 # If there is a warning, remove any object if it exists. if ofile: try: os.remove(ofile) except OSError: pass sys.exit(1) 若直接加 -w gcc选项,则会直接不显示Warning Posted by kk 2015-08-10 14:18:00 android, base « cpuset子系统 监控skb释放 » Copyright © 2016 - kk - Powered by Octopress
dun, duhnnnn…. The forboding sound of the forbidden warning. The warning that was forbidden. Oh the horror! Okay, so it really isn't that bad, but it sure sounds bad. I guess that's the point though. Let's https://thealaskalinuxuser.wordpress.com/2016/08/08/error-forbidden-warning/ take a look: [CODE] /home/alaskalinuxuser/Documents/projects/phones/compile/Liquid5/kernel/samsung/jf/drivers/video/msm/mdp.c:401:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=] error, forbidden warning: mdp.c:401 [/CODE] What we see here is the forbidden warning was given while https://forums.oneplus.net/threads/kernel-compiling-noob-thread.381142/ compiling the kernel. As you can see, the frame size is too big. It cannot exceed 1024 bytes, yet the compiled frame size was 1032 bytes. So, what do we do? Well, we only error forbidden have two options. Normally, we would have three options, as we could erroniously continue on using the [CODE] mka -i bootimage [/CODE] flag and compile despite the errors. This error however, cannot be overcome by this flag, as this problem is "forbidden". Yes, the compilation would continue, but it would not produce the kernel output. So, back to relavent options, of which we have two: increase the frame size error forbidden warning byte limit, or decrease the frame size. I don't know how to even begin doing the first option, so we will stick with the latter of decreasing the frame size. In this case it was incredibly easy. I was building the kernel with the arm-linuxeabi-4.8, and simply "upgraded" to 4.9. By doing so, the compiler was more "efficient" and built the smaller frame size which resulted in an error free build. You can choose which tool chain to use in your BoardConfigCommon.mk file, like so: [CODE] TARGET_KERNEL_CROSS_COMPILE_PREFIX := arm-linux-androideabi- TARGET_KERNEL_SOURCE := kernel/samsung/jf ------Or specify a custom one------ TARGET_KERNEL_CUSTOM_TOOLCHAIN := linaro-4.7-12.10/bin/arm-linux-gnueabihf- [/CODE] Linux - keep it simple. Share this:TwitterFacebookGoogleLike this:Like Loading... Related Posted in Android, compile compileerrorkernelsource Post navigation < Previous Porting Debian Linux to your cell phone part 3 of3Next > Using a fallback branch to overcome poor choice of repository branchnames Leave a Reply Cancel reply Enter your comment here... Fill in your details below or click an icon to log in: Email (required) (Address never made public) Name (required) Website You are commenting using your WordPress.com account. (LogOut/Change) You are commenting using your Twitter account. (LogOut/Change) You are commenting using your Facebook account. (LogOut/Change) You are commenting using your Google+ account. (LogOu
this thread only Search this forum only Display results as threads Advanced Search Products OnePlus 2 OnePlus 2 Development Page 1 of 2 1 2 Next > 1 Kernel compiling [noob thread] Oct 7, 2015 Sneed Level: Gingerbread Oct 7, 2015 Sneed, Oct 7, 2015 : Hi everybody, I'm not a developer, I'm only a noob PC geek ^^ Since a few days a wan't to compile the stock kernel, but it ends in an error. I have set a build environement like the google kernel howto and mixed it up with 64bit style. What I have done with my Ubuntu 14.04: - install build tools: $ sudo apt-get install gcc bison g++-multilib git gperf libxml2-utils make python-networkx zlib1g-dev:i386 zip u-boot-tools openjdk-7-jdk - install repo tools: $ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo chmod a+x ~/bin/repo - make working directory: $ mkdir WORKING_DIRECTORY $ cd WORKING_DIRECTORY - clone OnePlus git repo: git clone https://github.com/OnePlusOSS/android_kernel_oneplus_msm8994.git - Get into the cloned repo: $ cd android_kernel_oneplus_msm8994/ - taking a look at git log $ git log --max-count=1 kernel - download a prebuild toolchain (aarch64-gcc4.9) $ git clone https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9 - correct path of two files (workaround from regalstreak on Github, thanks!) https://github.com/OnePlusOSS/andro...mmit/9699d3790bda4f40ac603c9b0819e2f26f38a0b3 - building $ export ARCH=arm64 $ export SUBARCH=arm64 $ export CROSS_COMPILE=aarch64-linux-android-4.9/bin/aarch64-linux-android- $ git checkout 8fe727185a3a8c5b6ca29a2e62775827bac53ca0 $ make msm8994-OnePlus2_defconfig $ make My errors in the 2nd post.... Last edited: Dec 30, 2015 #1 #HYPEorGTFO likes this. Sneed Level: Gingerbread Oct 7, 2015 Sneed, Oct 7, 2015 : It compiles just a few minutes. "jump_label.h" makes this error. Anybody else had this problem and how can I fix it? ^^ This is the console output at the error: /home/sneed/WORKING_DIRECTORY/android_kernel_oneplus_msm8994/arch/arm64/include/asm/jump_label.h: In function 'do_page_fault': /home/sneed/WORKING_DIRECTORY/android_kernel_oneplus_msm8994/arch/arm64/include/asm/jump_label.h:30:2: warning: asm operand 0 probably doesn't match constraints error, forbidden warning: jump_label.h:30 make[1]: *** [arch/arm64/mm/fault.o] Fehler 1 make: *** [arch/arm64/mm] Fehler 2 #2 keessonnema Level: KitKat Oct 7, 2015 keessonnema, Oct 7, 2015 : I forgot the names of all the devs w