kernel

  1. Bobi B.

    How to specify kernel configuration when compiling out-of-tree kernel modules?

    Or, having an out-of-tree (i.e. not in /usr/src/sys) custom FreeBSD kernel module, how one can specify a kernel configuration, like GENERIC, the module shall be built against? Here is a very small kernel module that can be compiled, but cannot be loaded on a stock FreeBSD 12. Makefile: KMOD=...
  2. M

    FreeBSD 12.0 - module init function is called few times - Raspberry Pi 3.

    Hi, I write a driver of LCD, witch use SPI and GPIO and works on kernelspace. Source code is available on my github: https://github.com/mattpro/freebsd_test2/blob/master/lcd.c I'll try to test spi but I find strength things. When I load module into kernel: kldload ./lcd.ko I see that init...
  3. jontheil

    Solved Some necessary steps missing to install a new kernel

    Some months ago, I had some problems when upgrading to FreeBSD 11.2 https://forums.FreeBSD.org/threads/cannot-make-buildworld-after-failed-upgrade-to-11-2.67177/ After using some of the nice advices, I ended up with a usable system, even though some inconsistencies were obvious. I did wget...
  4. Y

    OSS Sound Quality

    The default settings of oss are insane. These settings are for pure quality without cracking or any other kind of distortion and low-quality annoyance. This is an passthrough, bypassing some features you don't need. This gives you full quality without thinking about it anymore. sysctl.conf...
  5. focaccio

    Unix and Linux - Network Subsystems

    Hi All, I'm a network engineer looking to better understand the network subsystem of FreeBSD (unix systems) and in particular how it differs from the linux kernel network subsystem. Any good links or books? I believe iproute2 (this is a package, not a subsystem, right?) is used by linux, so...
  6. S

    Why is PPS_SYNC disabled in GENERIC kernel?

    Several years into compiling custom kernel to let GPS provide precise time-keeping signals, I still wonder why is that not enabled in stock kernel? With tons of modules for hardware bundled by default, many of which are obsolete, expensive or otherwise rare, it is surprising that such a...
  7. B

    The perennial Xorg inside jails patch

    I've modified the patch I found on these fora to allow /dev/kmem write access inside jails. The security arguments are hopefully well known: there isn't any. It's still useful for me in order to test different Xorg configs, desktop environments, and ports trees without potentially screwing up...
  8. Farhan Khan

    Get thread from within a module

    Hi all, I am doing some light experimentation with the kernel and am writing a module. I am trying to have a /dev file functions as a TCP listening socket. So if you do cat /dev/tcp/5555, it would be the equivalent of nc -l 5555. My general strategy is to create a socket by jumping into the...
  9. decuser

    Kernel exploration via FreeBSD Kernel Internals: An Intensive Code Walkthrough, by McKusick

    I would like to set up a VM to work through the McKusick videos and material. Reading code and talking through it is great, but I really want to be able to tweak bits and see my changes in action. Since the release is available online, I know that I can download pretty much ISO or vm of the...
  10. goshanecr

    amdtemp not shown AMD A6-9500E sensors

    Good day! I have a PC with such processor: CPU: AMD A6-9500E RADEON R5, 6 COMPUTE CORES 2C+4G (2994.44-MHz K8-class CPU) Origin="AuthenticAMD" Id=0x660f51 Family=0x15 Model=0x65 Stepping=1...
  11. C

    Solved Fatal trap 18: integer divide fault while in kernel mode after compile kernel on Freebsd 11.1

    Hi , I facing the problem above after compile the kernel. Each time FreeBSD will loop boot several time until can go to login page. My cpu info hw.model: Intel(R) Core(TM) i3-4160 CPU @ 3.60GHz hw.machine: i386 hw.ncpu: 4 my kernel info added my option from generic one. # # GENERIC --...
  12. R

    C/C++ How can i get the mount_point & absolute_path by the installed file struct?

    I'm writing a simple hook to open / openat. Like this static int openat_hook(struct thread *td, register struct openat_args *uap) { // print uprintf(" SYS_openat: \"%s\", flags: %d, mode: %X fd: %d\n", uap->path, uap->flag, uap->mode, uap->fd); get_whole_addr(td, uap); return...
  13. M

    Dtrace does not work

    Hi, I want to get some specific I/O data from FreeBSD. IOStat command does not return what I want, so I think about using dtrace. The problem is that I am getting this error while executing dtrace command: [2.3.1-RELEASE][admin@machine]/usr/share/dtrace: dtrace -s iotime.d dtrace: failed to...
  14. Harmnot

    Should i build new kernel ?

    Hey, I just finished install FreeBSD 11 on external harddisk, and I want to ask about kernel, should I rebuild kernel after installation? I was building kernel , and I cancel it after a hour because it was take very long time and my laptop got very hot on for it , I follow This instructions to...
  15. andrewschools

    Compile kernel module with modified object file

    I'm not sure if this is the right forum for this sort of question. If not, forgive me. I made a change to this file: /usr/src/sys/modules/usb/usb/ng_lookup.c and have ran a make which produces many object files. The one I am concerned with is /usr/src/sys/modules/usb/usb/usb_lookup.o. Now I...
  16. Rastko

    Using laptop without battery

    If I take out the laptop battery, do I confuse the acpi system? I get kernel spam containing: No handler for Region [RCM0] acpi_ec0: evaluation of query method _Q42 failed: AE_NOT_EXIST Is it due to me removing the battery, and if so, how can I tell acpi system not to look for it?
  17. Petr Fischer

    Solved FreeBSD 11.1 has begun to crash accidentally - how to debug?

    Hello, FreeBSD 11.1 (somewere after 11.1-RELEASE-p1) has begun to crash sometimes - I am on Xorg + i3 (often in a Firefox) and suddenly Xorg crashes, I can see a few lines in a console (for a fraction of a second) and then, laptop restarts. How can I find out what happened? There is nothing...
  18. rigoletto@

    Intel bug incoming.

    Intel Bug Incoming. EDIT: It seems sh!t will get pretty serious: Intel's CEO Just Sold a Lot of Stock UPDATE: 'Kernel memory leaking' Intel processor design flaw forces Linux, Windows redesign
  19. vermaden

    Move FreeBSD kernel messages (white) to second console

    By default FreeBSD puts kernel messages (white color) on the first console. I know I can disable them with boot_mute in the /boot/loader.conf file, but is there a way to move them to second console instead of disabling them? ... or to redirect them to some file instead of disabling them...
  20. Farhan Khan

    dtrace probe not listed

    I do not see the function ifhwioctl listed when I run dtrace -l. This function is located in /usr/src/sys/net/if.c. I thought maybe this was optimized out, so I set the following in my /etc/make.conf CFLAGS= -O0 -fno-inline But it is still not listed. What may be causing this lack of probe?
Top